tallphil.co.uk version 4
Welcome to the future - v4 is live!
My blog at tallphil.co.uk was hacked a few weeks ago and taken down by spammers. I got it back up and running again, but earlier today the hosting account was suspended due to spam being sent out (again).
The tallphil.co.uk WordPress installation has been annoying me for a little while now. I’ve been running the site with it for years now and it’s under constant attack. I’ve had to disable site comments, implement stronger and stronger admin auth (2-factor, captchas) and try to strip the site back to basics just to keep it safe. As a result, the WordPress installation was getting increasingly bloated, slow to load and difficult to use. I love WordPress, but for this site I’ve had enough.
So, I’ve moved to Jekyll.
Implementing the change
A move to Jekyll has been in the back of my mind for a while - I really like writing in markdown and the idea of having a static site is quite appealing for a simple site like this. It is much more difficult to hack and should be lighting fast to load. It also fits in well with my regular tools and workflows that I use for work every day.
I was quite nervous about migrating old posts from the WordPress site to Jekyll format. However, this turned out to be ridiculously easy, made possible with a WordPress plugin called Jekyll Exporter. This is literally a one click tool which generates a load of markdown files ready to dump straight into Jekyll. It worked first time - all I had to do was download all of my image uploads and do some find and replace work to get the image embedding links to work.
When I was migrating old posts, I decided to set a threshold and not bring over anything older than 2011. That was roughly when I started writing blog posts about code and technical topics rather than random gifs that I’d found on the internet.
Theme me up, Scotty
Once the back end was in place, I was able to run the new Jekyll site locally and started playing with the front end a little. I actually really liked the default theme that Jekyll came with (you can see an example here) so used that as a starting point.
Along the way, I was totally seduced by the amazing history.js package and @joelhans tutorial tutorial about using this with Jekyll. Every blog post has its own page, but when following a link in the left sidebar, front end JavaScript pulls this in behind the scenes, grabs the part of the page that contains the post content and injects it into the already loaded webpage that you’re looking at. Importantly, it also changes the URL and browser history, so everything works as if you had reloaded the page.
This allows me to write nice (very subtle) animations when you change posts, plus the whole site is a bit speedier and spiffier. Honestly, it’s probably only me who will notice the difference, but it made me happy :)
GitHub Pages
Finally, once everything was working locally as I wanted, it was time to put the site online. The main hosting package for tallphil.co.uk had been hacked and was sending out spam and the only really safe way to get around that is to totally delete it. Whilst I could have created a new package to host the Jekyll site, it seemed silly not to use GitHub Pages. I wanted to store the site contents on GitHub anyway, so the free Jekyll hosting done by GitHub based on those files seemed like a no brainer.
A quick config change and DNS update later, and the site is running! If you’re curious, you can see the source code that the website is based on here, including this markdown file!
Archiving the old stuff
I am a sentimental old fart and I don’t like websites to die and vanish forever. So I used SiteSucker to download a static copy of the WordPress front-end site, which I have made available here. If you’re curious, you can also see version 2 and version 1 of the tallphil.co.uk site, along with fragments of the truly ancient all that jazz website that predates everything and goes back to the origins of my web design career as a teenager.
beta.tallphil.co.uk is a new subdomain that I created when doing this switch. tallphil.co.uk is my oldest domain and was the first web hosting package that I ever owned. As such it was a graveyard of old subsites and experiments, all of which were mixed in with the WordPress blog install. I’ve moved these things over to beta.tallphil.co.uk where they can live on in isolation and safety.
Plans for the future
I wasn’t planning on releasing this new site just yet, but the second
hack sort of forced my hand. I think that the styling could do with
a bit of improvement to make it a little more colourful and exciting.
I would like subheaders such as the one above to be clickable to give
deep linking (eg. http://tallphil.co.uk/tallphil-v4/#plans-for-the-future
)
and a load of other similar tweaks.
I have created a few tool documentation websites using markdown source files recently (eg. MultiQC and Cluster Flow). I wanted to keep the markdown with the main code, so wrote my own system from scratch. However, GitHub recently announced that it’s now possible to run GitHub Pages websites with Jekyll from subdirectories of a repository, so this Jekyll site may be the first of many..