This is a sample project built with the web framework Koa following the best nodejs practices. It includes a test suite built with Jest.
Make sure do you have installed docker
and docker-compose
. To check if they are installed run in the command line:
sudo docker -v
sudo docker-compose -v
The commands listing below run in sudo
mode but if you have configured docker to run without sudo
, you can run the commands without it.
sudo docker-compose run node yarn
DATABASE=mongodb:https://mongo/database_example
JWT_SECRET=some_secret_value
PORT_SERVER=3000 #default port
To run the project just do:
sudo docker-compose up
To run all tests suite:
sudo docker-compose run node yarn test