-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
59 lines (54 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
version: '3'
services:
backend:
image: ecoeats-backend:latest
build: ./backend
ports:
- "8022-8023:8022"
environment:
- PORT=8022
- URL=${URL}
- JWT_SECRET=${JWT_SECRET}
deploy:
replicas: 2
restart_policy:
condition: on-failure
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
frontend:
image: ecoeats-frontend:latest
build: ./frontend
ports:
- "3000-3001:3000"
depends_on:
- backend
environment:
- REACT_APP_API_URL=http://loadbalancer/api
deploy:
replicas: 2
restart_policy:
condition: on-failure
loadbalancer:
image: ecoeats-nginx:latest
build: ./nginx
ports:
- "80:80"
volumes:
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
depends_on:
- backend
- frontend
mongo:
image: mongo:latest
volumes:
- mongo_data:/data/db
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
volumes:
mongo_data: