In late 2014 whilst working on AngularJS frontend apps on Herkou, I discovered and recommended Harp web server to the team. Harp is a powerful static file web server with built-in template proprocessing. It helped us eliminate much tedious build tasks and ruby gems from our static client projects. If you haven’t heard of Harp, have a read of Sintaxi’s Introducing Harp.
Half a year later, I have also decided to migrate over to harp for my personal blog. For smooth transitioning of my articles and meta data from Jekyll, I used the awesome Jekyll2Harp. My blogs now consists of just my articles and HTML/CSS templates, and Harp preprocesses all my static files on the fly. No more Jekyll gems, no more compile commands. Also I no longer need to prefix my blog posts with the timestamp which is really neat. Lastly my Disqus comments was moved using Disqus Migration Tools.
The next question is where to host my harp blog. There are several options:
- Use static
harp compileto deploy to GitHub Pages. But that kinda beats the point of drop in preprocessing.
- I tried Harp.io for a while, it’s very easy to use but and I highly recommend it.
However as a Software Engineer I’m not a fan of using Dropbox as source control and wanted to be more hands on. In the end I settled on the following DIY solution:
- Architecture My blogs are effectively Harp Microservices within Docker containers. I created my own minimal AlphineLinux Harp containers.
- Build: GitHub commits triggers Quay.io, which is Continuous Delivery for Docker. See my build status:
- Deploy Successful Docker builds kicks off deployment webhook in Tutum Cloud. Tutum takes care of Container orchestration and load balancing.
- Virtual Machines provided by Windows Azure.
- DNS and CDN using the free and powerful Cloudfare.
It’s a bit of a overkill but it was quite a fun process and a good refresher on the similar setup I built at work a few months back. I will write a more detailed blog in the future in regards to the Tutum Cloud and Docker container setup.