This repository has been archived by the owner on Oct 20, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Staging & Production Environments
Nathan Struhs edited this page May 25, 2019
·
4 revisions
The production and staging environments are hosted on Heroku.
- Production: http://batabase.herokuapp.com
- Staging: http://batabase-staging.herokuapp.com
You will need to configure local remotes to both Heroku apps. https://devcenter.heroku.com/articles/git#creating-a-heroku-remote
Production:
> heroku git:remote -a batabase
> git remote rename heroku production
Staging:
> heroku git:remote -a batabase-staging
> git remote rename heroku development
To push changes to the staging environment:
> git push staging development:master
Where staging
is the name of the remote, development
is your local branch you want to push, and master
is the remote brach to push to. In other words push my development brach to the master branch on the staging environment
.
Anytime new data is added from a new db dump, the data will need to be moved from your local database to the Heroku database.
Note! Tread carefully, pg:reset will drop the database.
> heroku pg:reset --remote staging
> heroku pg:push batabase_development DATABASE_URL --remote staging