Skip to content

Latest commit

 

History

History
67 lines (44 loc) · 919 Bytes

File metadata and controls

67 lines (44 loc) · 919 Bytes

Node-Express-Tsoa-Swagger-TypeORM-Starter

Node, Express, Tsoa, Swagger, TypeORM, Docker, PostgreSQL Starter Project

Set up Configuration

Copy and fill out the env file

cp .env.example .env
# Server PORT
PORT=

# DB Configuration
DB_HOST= // if you are using docker, please set as 'db'
DB_USER=
DB_PASS=
DB_NAME=

Running Server

With Docker

1. Build docker image

docker-compose up --build

2. Running server with detach mode

docker-compose up -d

Without Docker

1. Install npm packages

yarn install or npm install

2. Running with development mode

yarn dev or npm run dev

3. Running with production mode

yarn build or npm run build
yarn start or npm start

Swagger API Docs

http://localhost:${PORT}/docs

Notes

  • Tsoa doesn't like Omit<>. Use Pick<> instead, even if more verbose