Simple Config To Push Your RoR app To Heroku using Pg:
- Let sqlite just in development & test environment
group :development, :test do
gem 'sqlite3', '1.3.12'
end
- Add pg in production env
group :production do
gem 'pg', '0.18.4'
end
- Prepare to deploy for production, just to update the Gemfile.lock
bundle install --without production
- Commit changes
git commit -a -m "Update Gemfile for Heroku deployment"
- We create our heroku app, beeing in our project root folder
heroku create name_of_the_app
- We push all online
git push heroku master
- Migration in remote db
heroku run rake db:migrate
- Now access your app in your brower: https://name_of_the_app.herokuapp.com/