1.2.6 • Published 5 years ago
@yad2/service-scaffolding v1.2.6
Microservices Scaffolding Tool
Opinionated Fastify based microservice boilerplate. This boilerplate provides a solid pattern that developers can use to scaffold and start develop a Fastify (NodeJS) based microservice within seconds.
Contains
- Pre-configured Babel, ESLint, Prettier,
- Swagger documentation and Swagger UI.
- Fastify application with CORS support and example routing.
- Docker environment ready for development (using nodemon) and production (using pm2 with cluster mode).
- Jest, Chai and Supertest configuration for Unit and integration tests.
- Example documentation files.
- Gitlab CI configuration file.
- k8s configuration files.
Installation
- Just run
npx @yad2/service-scaffolding
:)
Getting started
Once you have installed the boilerplate, running it is easy:
- Run
npm i
- Run
npm start
Point your browser at http://localhost:3000, you should see the example route.
Swagger documentation is available at: http://localhost:3000/documentation
Running tests
Running npm test
will run:
- Unit tests
- Integration tests
- ESLint checks
*** You can run npm run eslint:fix
for fixing code using ESLint.