-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
75 lines (68 loc) · 1.33 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# docker-compose.yml
version: '3.5'
services:
flask:
image: webapp-flask
build:
context: .
dockerfile: Dockerfile-flask
environment:
- ENV=development
- PORT=4000
- DB=mongodb://db:27017/
volumes:
- "./:/app"
depends_on:
- db
restart: always
db:
image: mongo:latest
container_name: "db"
environment:
- MONGO_DATA_DIR=/usr/data/db
- MONGO_LOG_DIR=/dev/null
volumes:
- ./data/db:/usr/data/db
ports:
- 27017:27017
command: mongod --smallfiles --logpath=/dev/null # --quiet
redis:
image: redis:latest
ports:
- 6379:6379
nginx:
image: webapp-nginx
build:
context: .
dockerfile: Dockerfile-nginx
ports:
- 3000:80
depends_on:
- frontend
- flask
frontend:
container_name: frontend
build:
context: .
dockerfile: Dockerfile-frontend
volumes:
- './frontend/:/usr/src/app'
- '/usr/src/app/node_modules'
environment:
- NODE_ENV=development
- CHOKIDAR_USEPOLLING=true
worker:
container_name: worker
build:
context: .
dockerfile: Dockerfile-worker
environment:
LOCAL_SETTINGS: /app/settings.cfg
volumes:
- "./:/app"
depends_on:
- redis
- db
networks:
default:
name: flask