Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rwarbelow/ab2f7578bdc9186cca3505adeb4ce66c to your computer and use it in GitHub Desktop.
Save rwarbelow/ab2f7578bdc9186cca3505adeb4ce66c to your computer and use it in GitHub Desktop.
Seeding a PG database using Sequelize, Node, and Elastic Beanstalk
  1. SSH into your EC2 instance: $ ssh -i <NameofKeyPair>.pem ec2-user@123.123.123.123
  2. $ cd /var/app/current
  3. ./node_modules/.bin/sequelize db:seed:all --env production --url postgres://[username]:[password]@[host]:[databaseport]/[databasename]

For example: ./node_modules/.bin/sequelize db:seed:all --env production --url postgres://taskmanager:taskmanager@taskmanager.ca1ksgalbb7j.us-east-1.rds.amazonaws.com:5432/taskmanager

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment