-
Notifications
You must be signed in to change notification settings - Fork 109
/
docker-compose.yaml
83 lines (70 loc) · 1.55 KB
/
docker-compose.yaml
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
version: '1'
services:
backend:
container_name: backend-app
image: backend-app:1.0
environment:
- NODE_ENV=docker
build:
context: backend
dockerfile: Dockerfile
ports:
- 5000:5000
links:
- mongodb
mongodb:
image: mongo
ports:
- 27018:27017
environment:
- MONGO_INITDB_ROOT_USERNAME=admin
- MONGO_INITDB_ROOT_PASSWORD=password
volumes:
- mongo-data:/data/db
healthcheck:
test: echo 'db.runCommand("ping").ok' | mongo mongo:27017/test --quiet
interval: 10s
timeout: 10s
retries: 5
start_period: 40s
mongo-express:
image: mongo-express
restart: always
ports:
- 8080:8081
environment:
- ME_CONFIG_MONGODB_ADMINUSERNAME=admin
- ME_CONFIG_MONGODB_ADMINPASSWORD=password
- ME_CONFIG_MONGODB_SERVER=mongodb
depends_on:
- "mongodb"
frontend:
container_name: frontend-app
image: frontend-app:1.0
environment:
- NODE_ENV=docker
- REACT_APP_API_BASE_URL=http://backend:5000
build:
context: frontend
dockerfile: Dockerfile
ports:
- 3100:3000
depends_on:
- backend
user-frontend:
container_name: user-frontend-app
image: user-frontend-app:1.0
environment:
- NODE_ENV=docker
- REACT_APP_API_BASE_URL=http://backend:5000
build:
context: user-portal-frontend
dockerfile: Dockerfile
ports:
- 3200:3000
depends_on:
- backend
- frontend
volumes:
mongo-data:
driver: local