-
Notifications
You must be signed in to change notification settings - Fork 225
/
docker-compose.yml
44 lines (44 loc) · 1.07 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
version: "3.3"
services:
nginx:
depends_on:
- client
- backend
restart: always # because it is routing traffic to our entire app
build:
dockerfile: Dockerfile
context: ./nginx
ports:
- '80:80'
client:
build:
context: ./client
dockerfile: Dockerfile
#ports:
# - '3000:3000'
volumes:
- /app/node_modules # Inside the container, don't try to override this folder, just leave as is
restart: on-failure
container_name: client
backend:
build:
context: ./backend
dockerfile: Dockerfile
#ports:
# - '3001:3001'
restart: on-failure
container_name: backend
volumes:
- /app/node_modules # Inside the container, don't try to override this folder, just leave as is
env_file:
- ./env/backend.env
mongo:
image: 'mongo'
container_name: 'mongo-db'
ports:
- '27017-27019:27017-27019'
volumes:
- ./db/init-mongo.js:/docker-entrypoint-initdb.d/init-mongo.js:ro
- ./db/mongo-volume:/data/db
env_file:
- ./env/mongo.env