Deploying Ghost 1.X to Heroku

Ghost is a great blogging tool, however there are some new caveats to look out for when using Ghost 1.X on you site.

Assuming you've been though the process described here :
The first problem you will notice is that if you're using a public repository, you'll be commiting your config files with all your DB creds in it...ew.

Heroku has enviormental varibles, but how do we get Ghost to recognize them and use them for our database connection? Simple:
$ heroku config:set \ database__connection__user=username \ database__connection__password=password \ database__connection__host=host \ database__connection__database=db

You should have all of these from when you created your Heroku app and its SQL database. Ghost will update the database object in your prodution JSON file accordingly.

All that's left is to initialize your Database! Run heroku run "knex-migrator init" and you're all good to go!