archive about

Crafting a blog

I'm finally happy with my blog. Not the content. The engine that hosts it.

TL;DR: The long story (kind of borring) of how I ended up writing my own static blog generator (bucket3) and how I replaced blog comments with "mentions" from other sites.

They weren't always called like this. But I've had blogs (or sites that resembled one) for more than a decade --actually, my first personal site, that used to be hosted at users.hol.gr/~vrypan/cactus/ [1], dates back to 1997, that's close to ancient for the Internet time-scale.

screenshot

Throughout these years, I was never satisfied with the underlying "engine". I went from HTML pages to PHPSlash, (a PHP port of the features of the then extremely popular slashdot.org), to drupal, to ez Publish, to wordpress and many others. I mostly hosted my content on my own server, but I'va also used most hosted blogging platforms, from blogger.com, to wordpress.com, to posterous.com, to tumblr.com. I've tried tweaking each platform to my likes, from playing with settings and themes to writing modules, but it never felt right.

There was always an underlying complexity I didn't like --for example, I moved from drupal to wordpress when I realized that wordpress had fewer features but was much more focused on blogging.

migrating from drupal to WP

This complexity is not always obvious at install. I mean, if you know what you are doing, setting up a wordpress blog is probably one of the simplest things. But as time went by, I could see it: updating my server software, managing my server, trying to figure out what's wrong with my DB settings (or is it the Apache?) that caused my blog to freeze. Dealing with a hacked server every once in a couple of years, or the few occasions when my blog was flooded with traffic that my cheap VPS couldn't handle.

But the worst part was ending a blog --because, don't be fooled, there will come a time when you will feel that you want to retire your blog, even if it is only to start a new one. I mean, I don't consider my posts to be of great importance, but they are important to me. I want my content preserved. Leaving a wordpress, or similar, site just running unattended will only result in a hacked zombie server, sooner or later. Retiring a blog means only one thing to me: converting it to static HTML [2] pages and hosting them somewhere -on a simple web server serving only HTML pages, or even better on a service like Amazon S3. I managed to do it, but it was never trivial.

After years of trials, I decided that I wanted my blog to have most features (not all) of a modern blog and in addition to be:

  1. static: all important elements had to be served by a simple HTTP server (even one as simple as Amazon S3)
  2. independent: it wouldn't rely on any other sites for my blog to render.

So four years ago, I decided to write my own blogging engine, bucket3. It was inspired by Jekyll [2] and other similar static blog generators. But I wanted it to be in Python. And I wanted it to work exactly the way I imagined such a tool should work: I wanted it to fit my own work flow and my very own special quirks.

I consider bucket3 to be a crafting project, not an engineering project. I had, and still have, no deadlines no specs. I don't look for the most efficient way to do things but the "right" way --and what's "right" is highly subjective here. It's not something that requires my attention, but my small side-project I spend time on when I need to do "something else". A small improvement here, a bug fix or a new feature there. Sometimes months go by without me touching the code and then I may work on it for a whole weekend. The fact that no one else seemed to use bucket3 until recently [3] made my life even easier: I could change anything I wanted without worrying I would break someone else's site.

About a year ago, I moved my main blog (the one you are reading now) to bucket3.

One of the most difficult problems was deciding what to do with comments. Had you asked me 6 years ago, I would have said that you can't have a blog without comments. But the Internet has changed since then, my audience has changed more than a couple of times, and I have changed too. I wanted some kind of interactivity on my blog, but that's hard to get on a static blog, and embedding a third party commenting system like Disqus seemed to beat the purpose (among other, of a site that has no third party dependencies when it comes to presenting it's content).

So, at first, I decided to go without any comments. Then, I tried hosting the "conversation" elsewhere: I would post a link to a Google+ or a HackerNews entry where people could post comments. It didn't feel right.

In the meantime, I discovered the IndieWebCamp community, where people have similar ideas. The tools they have implemented and their ideas of how the web should work, helped me a lot.

Little by little, I have finally implemented a solution that is quite satisfying to me. Now, there are two ways to "leave comments" on my posts.

The first one is by tweeting your comment together with a link to the post. Your tweet will show up at the bottom of the post. It may take some minutes or hours to show up, but that's OK: I'm not really interested in hosting conversations on my blog, but providing my readers with ways to give feedback.

The second one, is even better: Post a reply to your blog and link to my post. If you are using a service that supports pingback or webmention [4], a link to your post will show up under my post. (Again, it may take some time, from minutes to hours). That's how we should be doing it anyway --host our own content, even if it is a reply, on our own space and notify the other person that there is a reply.

In both cases, the "comments" are baked into the static HTML of my post. I like this. It means that even if I browse my blog posts on my computer, in 20 or 30 years, the "comments" will be there.

bucket3-mentions

It probably makes little sense for most people. But for me, there's something deeply satisfying in knowing that I wrote from scratch the software I'm using to blog. I'll keep tinkering the code.


[1] An archived version of it can be found at vrypan.net/archive/cactus/

[2] I've actually archived vrypan.net/radio (my fisrt podcast), vrypan.net/weblog, and vrypan.net/log by using various techniques.

[3] Jekyll played a huge role in making static blog generators fashionable among coders again. But the idea is not new. Converting a bunch of (text or HTML) documents to a bunch of HTML pages that consist a site, was one of the first techniques used to create websites. Even my first website, was rendered by a hacked version of sgmltools, that converted SGML to HTML.

[4] A couple of months ago, Nikos became user #1 of bucket3, as far as I know.

[5] Wordpress.com, and self-hosted wordpress sites will send a pingback. Tumblr and Blogger will not, as far as I know. Pick a blog hosting service that's a good netizen, not just the fancier one.