deploying to heroku - wbobeirne/nycda-ecommerce-server GitHub Wiki

First Time Deploy

  1. Run heroku create, make sure you only run this once
  2. Run heroku addons:create heroku-postgresql:hobby-dev to add Postgres
  3. Add your environment variables by running heroku config:set [CONFIG_VAR_KEY]=[config var value] for each config variable except the DB_* ones.
    Do not run this command literally, you need to fill in the values
  4. Run git push heroku master to deploy your application
  5. Run heroku open to open your app in the browser
  6. If anything went wrong, check heroku logs --tail to find any errors

Subsequent Deploys

  1. Run git push heroku master to deploy your application
  2. Run heroku open to open your app in the browser
  3. If anything went wrong, check heroku logs --tail to find any errors

Importing Watch Data

If you want to import the watch data from part one, simply run:

heroku pg:backups:restore 'https://s3.us-east-2.amazonaws.com/wbobeirne-misc/ecommerce-heroku.dump' DATABASE_URL

Restart Server

If you need to restart your server, but don't have new code to deploy (For instance, you want to see error messages again from a failed build) run heroku restart

⚠️ **GitHub.com Fallback** ⚠️