News for hackers. Stuff that matters.

Ask HN: Self-host a blog securely – how? (WP? Staticgen?)

I have some material for a tech blog I'd like to put someplace.

I'd like to self-host it, but sometimes the part of the drive that enables creativity contradicts / is interfered with by the part of the brain that is required for technical planning, even something as minor as a tech blog setup.

At least for me.

I'm thinking I host a WordPress instance privately, at home, and I use a staticgen system (Pelican??) to export and push that out to a STATIC public site on a VPS I control. It still feels like a lot of work though.

I'm a systems guy and I'd like the WYSIWYG-type platform on which I can focus on ideas and post my blog without worrying about security, hosting, etc. And it needs to be at least somewhat pretty, with a discus or other commentary plugin at the bottom and ability to show pretty screenshots.

Has anyone experimented with Wordpress -> Pelican or is there something better?

If I spend too much time hacking away at edge conditions, then that's less time I get for creativity.

Any ideas would be appreciated.

( 16 comments | 6 points | on HN )
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by samirmalpande on Sunday April 09, 2017 @03:55PM (#14074058)
We are using SimplyStatic (https://wordpress.org/plugins/simply-static/) for genrating a static site from WordPress. It has many options which make genrating and deplying a static site with WordPress easy.

If you want to host site on S3 you can use the fork of Simply Static https://github.com/kennu/simply-static-s3

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by mancerayder on Sunday April 09, 2017 @07:07PM (#14074818)
Wow, I think this has the most potential. I'm a fan of simplicity. I downloaded a theme, made a few edits and ran this plugin, and so far so good as a POC.

This is faster than having to learn Pelican and even those other systems which might also be great, but a bit heavy weight for my purposes.

Thank you, this might be the solution I was looking for.

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by dalerus on Sunday April 09, 2017 @08:58PM (#14075246)
Thanks for posting the static site plugin. I was looking for something like this. I've been using Wordpress forever and wanted something for personal use, but didn't want to host a public version of Wordpress.
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by akg_67 on Saturday April 08, 2017 @08:23PM (#14069803)
> I'm thinking I host a WordPress instance privately, at home, and I use a staticgen system (Pelican??) to export and push that out to a STATIC public site on a VPS I control. It still feels like a lot of work though.

What is the purpose of this exercise? Blogging or learning WP->static page migration path? If your purpose is blogging and you have no interest in admin and revenue generation, just host on WordPress.com. If you want more flexibility, just self-host WordPress.

Why make it more complicated by adding another path of WP->Static Pages?

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by mancerayder on Sunday April 09, 2017 @02:16PM (#14073581)
Why make it more complicated by adding another path of WP->Static Pages?

WordPress can pretty insecure if not micromanaged. It's often a vector for hacks, and requires meticulous updating.

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by mancerayder on Sunday April 09, 2017 @06:34PM (#14074700)
Here is some support for the claim that WordPress is insecure:

https://www.wordfence.com/blog/2016/03/attackers-gain-access...

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by seanwilson on Monday April 10, 2017 @04:25AM (#14076867)
That's why using a hosted option is a good idea so they take care of the security patches and backups for you.
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by thenomad on Monday April 10, 2017 @06:28AM (#14077313)
Hugo with Discus will do the job you're looking to complete: it's the approach I've taken with nearly all my sites these days, precisely because of the performance and security headaches.

You don't even need to run a VPS, although if you do so you can set up a nice publication pipeline with Git. But you can equally just throw the static content up on S3 or Google Cloud Storage, optionally with a CDN in front of it.

You can also run your blog on Gitlab if you feel inclined: they have a CI process meaning that when you commit new source content to your git repo, it'll automatically get built and appear on your site. I found the domain support a little flaky there when I tried it, but apparently they've updated their setup since then.

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by type0 on Saturday April 08, 2017 @06:52PM (#14069500)
Just use Caddy server with built in Hugo generator (you can choose it as an option when you download)
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by siscia on Monday April 10, 2017 @06:54AM (#14077397)
I am hosting a whole webshop about developer stickers(WallOfStickers.com) on a static web page.

Simply put your file in an S3 bucket and point the name server.

If you need a httpS connection (and I needed to take payments) simply use cloudfront and you are set.

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by Mz on Saturday April 08, 2017 @05:06PM (#14069042)
FWIW, I hand coded my first blog, moved it to self hosted Word Press to try to focus more on content, less on the back end stuff and later moved to BlogSpot. I have been much more satisfied with BlogSpot.

They also have very recently released new themes.

Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by rubatuga on Saturday April 08, 2017 @06:54PM (#14069510)
Ghost is great
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by stevenhubertron on Sunday April 09, 2017 @10:28AM (#14072455)
Jekyll + Netlify (CMS) and hosting.
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by smt88 on Saturday April 08, 2017 @04:24PM (#14068815)
Why self-host?
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by tedmiston on Sunday April 09, 2017 @01:58PM (#14073491)
With Ghost specifically it's because they charge way too much for the hosted service. $29/month ($19/month with annual commitment) for a blog is not worth it to me. If they offered a $5–10/month plan, I would probably use them over self-hosting.
Re:Ask HN: Self-host a blog securely – how? (WP? Staticgen?) by mancerayder on Saturday April 08, 2017 @04:39PM (#14068895)
I ask myself that a lot. Because I'm a devops / systems guy by trade, I already have my own services running on VPSes (minus a web site), because I have guaranteed content control. It's partially irrational, I'll admit. However, hosting it on someone else's tooling is Plan B.