Docker added

This commit is contained in:
NyxiumYuuki 2021-05-28 08:01:50 +02:00
parent 8cf6520224
commit 157c0e13a7
3 changed files with 39 additions and 68 deletions

View file

@ -1,82 +1,53 @@
version: '3.7'
networks:
net:
version: '3.8'
services:
frontend:
image: frontend
environment:
SERVICE_ADRESS: frontend
SERVICE_PORT: 4200
ports:
- 4200:4200
networks:
- net
service-authentication:
image: service-authentication
build: backend/service-authentication
command: node server.js
volumes:
- backend/service-authentication
- backend/service-authentication/node_modules
ports:
- 3001:3000
depends_on:
- mongodb-authentication
environment:
SERVICE_ADRESS: service-authentication
SERVICE_PORT: 3000
ports:
- 3000:3000
networks:
- net
NODE_ENV: development
service-message:
image: service-message
build: backend/service-message
command: node server.js
volumes:
- backend/service-message
- backend/service-message/node_modules
ports:
- 3000:3000
depends_on:
- mongodb-message
environment:
SERVICE_ADRESS: service-message
SERVICE_PORT: 3000
ports:
- 3001:3000
networks:
- net
service-notification:
image: service-notification
environment:
SERVICE_ADRESS: service-notification
SERVICE_PORT: 3000
ports:
- 3002:3000
networks:
- net
service-privateroom:
image: service-privateroom
environment:
SERVICE_ADRESS: service-privateroom
SERVICE_PORT: 3000
ports:
- 3003:3000
networks:
- net
NODE_ENV: development
mongodb-authentication:
image: mongo
networks:
- net
container_name: mongodb-authentication
environment:
- PUID=1001
- PGID=1001
volumes:
- ./backend/service-authentication/database:/data/db
ports:
- 27017:27017
- 27017:27017
restart: unless-stopped
mongodb-message:
image: mongo
networks:
- net
container_name: mongodb-message
environment:
- PUID=1000
- PGID=1000
volumes:
- ./backend/service-message/database:/data/db
ports:
- 27020:27017
mongodb-notification:
image: mongo
networks:
- net
ports:
- 27021:27017
mongodb-privateroom:
image: mongo
networks:
- net
ports:
- 27022:27017
restart: unless-stopped