- add a
.envfile in the root directory and set the missing###environment parameters
POSTGRES_HOST=127.0.0.1
POSTGRES_PORT=5432
POSTGRES_PORT_TEST=5433
POSTGRES_DB=storefront
POSTGRES_USER=###
POSTGRES_PASSWORD=###
BCRYPT_PASSWORD=###
SALT_ROUNDS=10
TOKEN_SECRET=###
docker-compose upto start the docker containernpm installto install all dependenciesnpm run db-upto set up the database and get access via http://127.0.0.1:5432npm run buildto build the app
npm run startto start the app and get access via http://127.0.0.1:3000
- add a
database.jsonfile in the root directory and set the missing###parameters
{
"dev": {
"driver": "pg",
"host": "127.0.0.1",
"port": 5432,
"database": "storefront",
"user": "###",
"password": "###"
},
"test": {
"driver": "pg",
"host": "127.0.0.1",
"port": 5433,
"database": "storefront",
"user": "###",
"password": "###"
}
}
npm run testto run all tests