Skip to content

Fastify template with Prisma, Redis, Swagger, Jest and JWT already setup

Notifications You must be signed in to change notification settings

OurUncomplicatedTemplates/fastify-prisma-redis-swagger-jwt-template

Repository files navigation

Project

Coverage Status

API documentation (Swagger)

Open http://localhost:3000/api/docs to view it in the browser.

Available Scripts

In the project directory, you can run:

make dev

To start the app in dev mode.
Open http://localhost:3000 to view it in the browser.

make prod

Build & runs production.

make test

Run the test cases.

make test-coverage

Run the test cases with code coverage.

make prisma-generate

Generate/regenerate the prisma client. This should be done after changing the prisma schema.

make migrate-dev

Migrate the prisma schema to the database and test database. This should only be run in the dev environment.

make migrate-reset

Clears the database and applies migrations. This should only be run in the dev environment.

make migrate-deploy

Deploys the pending migrations to the databases.

Learn More

To learn Fastify, check out the Fastify documentation.

Generate Ed25519 key pair

openssl genpkey -algorithm ed25519 -out private.pem
openssl pkey -in private.pem -pubout -out public.pem