This is the architecture of AMON NodeJS Test.
- Docker (https://docs.docker.com/install)
- NodeJS >
16.x.x
(prefer install with https://github.com/nvm-sh/nvm) - Postgres client (Osx:
brew install postgres
) - IDE (prefer https://www.jetbrains.com/webstorm/download)
- Clone repository
git clone https://github.com/amontech/amon-nodejs-test.git
- Use nvm to install node
nvm i
- Install node dependencies
npm i
- Unit tests
npm run test:unit
- Start/stop - restart dependencies
docker-compose down && docker-compose -f docker-compose.test.yml up --build db
- Run dependencies
npm run dependencies
- Create DB locally
npm run db:create
- Start api services
npm run service:api
docker-compose down
You can set environment variables in the .env
file, you can find examples in .env.sample