Follow these instructions to get the project up and running.
- Node.js >= 20 installed (or nix)
-
Clone the repository:
git clone https://github.com/your-username/your-project.git
-
Cd into the folder Install dependencies:
npm install --no-package-lock # installs yarn yarn
-
Compile the project to dist/
yarn build
-
Run the related services (mongodb)
docker compose up -d # to build the containers docker compose start # if you have already built the containers
-
Init the db
yarn db-init
-
Run the server
yarn express
The server will be running at http://localhost:PORT
You must replace PORT with the one in the .env
file.
Copy the versioned .env.example file to .env, and change it accordingly
Test are based on builtin Node's testing suite (starting from node 20)
Run with:
- Build the test
yarn build-test # build the test
- Run the related services (mongodb)
docker compose up -d # to build the containers docker compose start # if you have already built the containers
- Run the tests:
yarn run-test {args} dist-test/{path_to_folder} # or build and run yarn test {args} dist-test/{path_to_folder}
By Default all file named Test
will be run