Heroku Checklist
To enable features such as static asset serving and logging on Heroku please add rails_12factor
gem to your Gemfile.
# Gemfile
gem 'rails_12factor', group: :production
You should be running the same version of Ruby on Heroku that you're running locally.
Verify by checking your Ruby version locally
$ ruby -v
Now ensure you're Gemfile
has a versioned number of Ruby
# Gemfile
ruby "2.1.1"
If you're using a database be sure to migrate it and seed the db on Heroku
$ heroku run rake db:migrate
You can update your seeds.rb
file to clear out any previous data
# seeds.rb
User.delete_all # clears out all previous entries in users
User.create(name: "admin", password: "1234", password_confirmation: "1234", is_admin: true)
then...
$ heroku run rake db:seed
Add any environmental variables you're using
$ heroku config:set KEY=value
Trouble Shooting https://devcenter.heroku.com/articles/getting-started-with-rails4#runtime-dependencies-on-development-test-gems
you can do heroku run rake db:migrate, which will re-migrate the tables without the data, then heroku run rake:db seed