www.perdian.de Home Blog Conference talks Publications

My website and blog setup

I’ve seen quite a few postings on Hackernews and other sources describing the setup people have created to build and deploy their personal websites and blogs. So, jumping on the bandwagon, I’d like to give a small overview of how this website is built and deployed.

A bit of history

Way back (roughly 15 to 20 years ago) when I decided to have a personal website and blog about stuff that came into my mind, I set up (like so many others) a WordPress instance. This actually worked pretty well, but maintaining WordPress has become more and more of a hassle. At some point in time, I just deleted the whole thing.

But a couple of years ago, I wanted to get back into blogging and started looking for the best way to set up the whole infrastructure.

In the meantime, a bunch of static site generators had entered the stage that promised to be not only simpler than a fully-fledged CMS but also better suited to what I had in mind.

Interestingly, one of the first professional projects I started working on as a software engineer back in the early 2000s was a static site generator. It never really gained much traction (I guess the concept was simply way ahead of its time), but I can’t help but smile realizing that I’ve come “full circle”.

My current setup

So, a static site generator was (and still is) my way to go.

After trying a couple of products, I saw that GitLab used Middleman as their product of choice and took a closer look at it. It’s simple, easy to use, and implemented in Ruby. Being familiar with Ruby as a language and the whole Ruby ecosystem, it was an easy choice for me to start building my website using Middleman.

The website, including the blog (basically everything that is reachable at www.perdian.de, is hosted in a dedicated Git repository managed by a GitLab instance. On every push to the master branch of the repository, a GitLab CI script runs that builds the complete static website (including all assets). The assets then get packaged into an nginx Docker container, which is then deployed into a Kubernetes instance that forwards all incoming traffic to the nginx Docker container serving the static files.

To allow commenting on the blog articles, I’ve added utterances as an easy way to comment on otherwise static sites.

Conclusion

My setup is nothing fancy, but it definitely gets the job done: Writing a new blog article (like this one) simply requires me to add a new Markdown file, add some metadata, and push the new content to a Git repository. The CI pipeline will do the rest.

This still doesn’t help with the procrastination when actually writing down my thoughts, but it’s a nice start ;-)

Source: https://www.perdian.de/blog/2023/02/22/my-website-and-blog-setup/