npm config set '//registry.npmjs.org/:_authToken' "<INSERT NPM READ TOKEN HERE>" # Needed to install private NPM packages
yarn
The following will be started:
- Main Postgres instance
- Tokenization Postgres instance
- Ganache
docker-compose -f docker-compose-dev.yaml up -d
You can start these processes manually one by one with parameters you can find in the docker-compose-dev.yaml
file
To create/update database schemas execute the following:
yarn migrate:all
To reset database schemas and Ganache storage and recreate from scratch, execute the following:
docker-compose -f docker-compose-dev.yaml down -v
docker-compose -f docker-compose-dev.yaml up -d
sleep 5
yarn migrate:all
Usually, it is safe to regenerate Prisma client, especially after making changes to the schema or switching branches:
yarn db:migrate:generate
yarn build
yarn start
To seed the system with sample data necessary to develop, execute the following. It will submit data to the system over REST API and backend processes will save transactions on Ganache local chain
yarn seed:all:dev
The docker-compose-dev.yaml
file contains mailhog
service definition. This a mock SMTP server that allows you to
have insight into all email messages sent during development and testing. It exposes SMTP service on port 1025 and web
user interface on port 8025. Backend during development accesses it when the following is set in your .env
file: SMTP_URL=smtp://localhost:1025
. To see emails sent, navigate to http://localhost:8025/#
. SMTP mock service has
no data persistence, so you will lose all the email messages when it is restarted.
Requires heroku
command line tool
One time action:
heroku login
Make sure the latest master
branch is built
yarn clean && yarn && yarn build
Deploy staging
./deployment/deploy-staging.sh
Deploy prod
./deployment/deploy-prod.sh