Skip to content

bugtlp/backend-boilerplate

Repository files navigation

Backend Boilerplate

Description

Back-end starter repository based on Nest framework.

Installation

$ npm install

Settings

Create .env file in project root directory with:

DB_NAME=sample_db_name
DB_HOST=127.0.0.1
DB_USER=sample_db_user
DB_PASSWORD=sample_db_password
DB_PORT=5431
PORT=3000

PORT - Port of backend api

DB_HOST - Host of database. Default 127.0.0.1 or localhost

Running the app

# development
$ npm run start

# watch mode
$ npm run start:dev

# production mode
$ npm run build && npm run start:prod

Running the app via docker-compose

After .env created:

$ docker-compose up

By default will be created pg_data directory with database.

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

License

MIT licensed.

About

Backend Boilerplate

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors