A Shiny New Website

It’s been over 8 years since I last switched web platforms for ckdake.com, and it was time for a change. We are putting Gallery into hibernation, Drupal 6 is not going to get any more security updates once Drupal 8 is out (which should be soon), and the ongoing server/backup costs of keeping 130GB of photos on my site is not cheap.

At work, we recently launched a new bignerdranch.com, and my team did a fantastic job of building it as a ‘static’ site using jekyll. This included migrating a bunch of legacy Python, PHP, and Ruby code and an old Wordpress site.

With fantastic services like Flickr for photos and Vimeo for video, I set out to migrate my photos to Flickr and build a simple and fast ‘static’ site for ckdake.com. Here it is! The theme still needs a lot of work which is fine, and nanoc has been a lot of fun to get up and running.

Migrating Photos to Flickr

Flickr has a pretty straightforward API, and the Flickraw gem makes writing ruby code to talk to Flickr pretty easily. A few weeks ago I started on this and published the script that migrated my ~25,000 photos to Flickr here: gallery2flickr.rb.

This took about a week to run, and afterwards I spent a good bit of time properly naming sets, changing privacy settings, and copying over captions from my ‘stream’ abums. More time on the script could have automated some of this, but it’s done.

Getting Flickr Photos displayed here was a pretty straightforward block of Ruby code:

Pulling in Vimeo

Vimeo was really easy to pull in to, and the end result looks much better than the JavaScript widget I was using. It’s Ruby:

Preserving content and URLs

Getting content out of Drupal was a little bit more involved, and I didn’t spend the time to match up the ‘format’ of blog posts with file extensions or a content formatter. That might be nice, but I’m ok just fixing HTML files by hand when I notice something wonky. This script pulled out my content:

And here is the full ‘Rules’ file for nanoc that keeps around my old blog and page URLs. Note that nanoc by default does things like ‘/folder/page/index.html’ so I’ve configured it to do ‘/folder/page.html’ instead.

Onward

There is a mess of a UI to clean up, a pile of files to sort through, broken links to fix, etc. There are some PHP things that I need to figure out what to do with, and some shiny JavaScript libraries I want to play with. The ‘Projects’ section here is going to get some link-breaking cleanup as well, so stay tuned.

comments powered by Disqus