Skip to content
This repository has been archived by the owner on Apr 15, 2024. It is now read-only.

HybridPlanner/backend

Repository files navigation

Nest Logo

A progressive Node.js framework for building efficient and scalable server-side applications.

NPM Version Package License NPM Downloads CircleCI Coverage Discord Backers on Open Collective Sponsors on Open Collective Support us

Description

Nest framework TypeScript starter repository.

Docker usage

# Define the environment variables 
$ cp .env.example .env

# Start the containers
$ docker-compose up -d

# Enter the api container
$ docker-compose exec -it app bash

# Stop the containers
$ docker-compose down

Installation

$ npm install

Generate prisma behaviour

npx prisma generate

Run prisma migrations

npx prisma migrate reset

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run start:prod

Creating migration

Update migration after updating schema.prisma

npx prisma migrate dev --name "name of migration"

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

Mailhog

  • Make sure to run the mailhog container
  • Upate the values in the .env file MAILHOG_HOST either localhost or mailhog depending on the environment you are running (docker or local)
  • To use mailhog locally, go to http://localhost:8025/

Support

Nest is an MIT-licensed open source project. It can grow thanks to the sponsors and support by the amazing backers. If you'd like to join them, please read more here.

Stay in touch

License

Nest is MIT licensed.