A progressive Node.js framework for building efficient and scalable server-side applications.
API for survey project using Nest and TypeScript.
Install Docker
change variables in .env
file
#Port for example 3001
PORT=
#Cors Domain for example http://localhost:3000
CORS_DOMAIN=
#Google Auth 2.0
#https://console.cloud.google.com
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
#encuesta-mongodb is a name of mongodb container, change only for production
#(use external mongodb service in production, Mongo Atlas for example)
#https://www.mongodb.com/atlas/database
MONGO_URI='mongodb://encuesta-mongodb:27017/surveydb'
Replace docker-compose.yml content for this and then execute the commands from step 2.2
version: '3.8'
services:
backend:
build:
context: .
target: prod
dockerfile: Dockerfile
container_name: encuesta-api
image: encuesta-api
ports:
- ${PORT}:${PORT}
env_file:
- ./.env
docker compose -f docker-compose.yml build
- this command can be used for build and run docker image
docker compose -f docker-compose.yml up -d
- Author - Kamil Myśliwiec
- Website - https://nestjs.com
- Twitter - @nestframework
Nest is MIT licensed.