A feature-rich and production-ready NestJS starter with built-in enterprise-grade architecture and popular libraries. Supports TypeScript, PostgreSQL/MySQL, TypeORM, JWT Authentication, Docker, and other essential features.
- π Built with NestJS 10.x & Node.js 18+
- π TypeScript for type safety and better development experience
- ποΈ Clean Architecture and Domain-Driven Design principles
- π JWT Authentication & Role-based Authorization
- ποΈ TypeORM with PostgreSQL integration
- π Swagger API documentation
- π Request validation using class-validator
- π― Unit & Integration testing setup with Jest
- π E2E testing with Supertest
- π CI/CD pipeline with GitHub Actions
- π³ Docker & Docker Compose configuration
- π Winston Logger integration
- π Error handling & logging middleware
- π§ Mailer service integration
- π Database migrations and seeders
- π ESLint & Prettier configuration
- πΎ Redis for caching
- π Bull for queue management
- π Health checks endpoints
- Node.js 18+
- PostgreSQL
- Redis
- Docker (optional)
# Clone the repository git clone https://github.com/yourusername/nestjs-boilerplate.git # Install dependencies npm install- Copy
.env.exampleto.env
cp .env.example .env- Update environment variables in
.envfile
# Development npm run start:dev # Production mode npm run start:prod # Using Docker docker-compose up# Unit tests npm run test # E2E tests npm run test:e2e # Test coverage npm run test:covsrc/ βββ config/ # Configuration files βββ core/ # Core modules, guards, decorators βββ modules/ # Feature modules β βββ auth/ β βββ users/ β βββ ... βββ shared/ # Shared resources βββ main.ts # Application entry point Once the application is running, you can access the Swagger documentation at:
http://localhost:3000/api/docs # Generate migration npm run migration:generate -- src/database/migrations/NewMigration # Run migrations npm run migration:run # Revert migrations npm run migration:revert- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
If you find this project useful, please give it a βοΈ on GitHub!
- NETKO Solution
- NestJS Team for the amazing framework
- The open-source community for inspiration and support