A progressive Node.js framework for building efficient and scalable server-side applications.
- Installation
npm i -g @nestjs/cli
- Create New Entities
# --no-spec = don't generate testfile # create module nest g module <noun> # create service | business logic nest g service <noun> --no-spec # create controller | routes nest g controller <noun> --no-spec
-
PostgreSQL (TypeOrm)
- Create PostgreSQL using Docker
docker run --name postgres-nest -p 5432:5432 -e POSTGRES_PASSWORD=postgres -d postgres
-
[Linux] Systemd activate docker
systemctl start docker
-
Run Docker
docker container start postgres-nest
- Useful Command
docker container ls # list of containers run docker stop rm <container name> # stop container docker container rm <container name> # delete container
- JWT
- Passport-JWT
# development
npm run start
# watch mode
npm run start:dev
# production mode
npm run start:prod
For the sake of I am using this as a template, .env
are uploaded on this repo as well, make sure to add .env.stage.dev
& .env.stage.prod
to .gitignore
once cloned.
This project is GPL licensed.