- Database (typeorm).
- Seeding.
- I18N (nestjs-i18n).
- File uploads. Support local and Amazon S3 drivers.
- Swagger.
- E2E and units tests.
- Docker.
- CI (Github Actions).
- Logging
Before start, we need to install some packages and tools. The recommended version is the LTS version for every tool and package.
Clone the project with git.
git clone https://github.com/fajarantono/nest-restapi.git
This project needs some dependencies. Let's go install it.
npm install
npm run migration:run
npm run seed:run
Make your own environment file with a copy of env.example
and adjust values to suit your own environment.
cp .env.example .env
- Swagger: http://localhost:3000/docs
- Adminer (client for DB): http://localhost:8080
- Maildev: http://localhost:1080
Generate migration
npm run migration:generate -- src/database/migrations/CreateNameTable
Run migration
npm run migration:run
Revert migration
npm run migration:revert
Drop all tables in database
npm run schema:drop
Run seed
npm run seed:run
# unit tests
npm run test
# e2e tests
npm run test:e2e
Finally, Cheers ๐ป๐ป !!! you passed all steps.
Now you can run the project.
npm run start:dev