Fix up some stuff to be compatible with Heroku
Add more things for Heroku