Blogging with Marley on Heroku
Categories: ruby, marley, heroku
Marley
http://www.restafari.org/introducing-marley.html
Marley is a ruby app built upon the Sinatra web framework. It supports comments and themes out of the box and content is written with a combination of Markdown and html/css/whatever else.
Heroku
Heroku provides a Ruby cloud platform as a service. Once your Ruby app is deployed to Heroku it can be easily scaled up or down and customized with the use of helpful add-ons.
Setting up your blog
Follow the Installation & Setup instructions on http://www.restafari.org/introducing-marley.html to get Marley running in your development environment. I checked the master branch out from github and really only tweaked the erb and css files to customize my blog layout. I also added a .gems manifest file in the root of my app with the following contents:
rdiscount --version 1.5.5
rdiscount was the only gem required by Marley that wasn't available to my Heroku app by default. Once you add the gems manifest file and push to Heroku, rdiscount will be installed on your app's dyno.
Follow the guidelines laid out in the Heroku quick start guide to get your app up and running: http://docs.heroku.com/quickstart
The only other hurdle I encountered was deploying the SQLite database. Finally I gave up and added the empty data/comments.db file to version control and that worked. Ideally, the heroku db:push sqlite://path/to/my.db command would do the trick but I couldn't get it to work.