You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
spot2gether/docker-compose.yml.example

38 lines
729 B
Plaintext

version: '3'
services:
mongodb:
image: mongo:5.0
environment:
- MONGO_INITDB_ROOT_USERNAME=spot2gether
- MONGO_INITDB_ROOT_PASSWORD=spot2gether
backend:
image: node:alpine
restart: always
expose:
- 3000
volumes:
- ./backend/:/home/node/app/backend/
- ./helpers/:/home/node/app/helpers/
working_dir: /home/node/app/backend
environment:
- NODE_ENV=production
command: sh -c 'npm i && nodejs index.mjs'
links:
- mongodb
depends_on:
- mongodb
frontend:
build:
context: ./frontend
dockerfile: ".Dockerfile"
restart: always
ports:
- "8080:8080"
links:
- backend
depends_on:
- backend