-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
62 lines (57 loc) · 1.48 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
version: "3.3"
services:
flask-api:
build:
context: ./flask-api
dockerfile: ./Dockerfile
volumes:
- ./flask-api/:/root/
- ./NLP/':/root/NLP
restart: on-failure:10
expose:
- "5000"
container_name: flask-api
tty: true
stdin_open: true
networks:
- mindnet
node-api:
build:
context: ./node-api
dockerfile: ./Dockerfile
volumes:
- ./node-api/:/root/
restart: on-failure:10
expose:
- "3000"
container_name: node-api
#command: pm2 start /node-api/node-api.json --no-daemon
#command: node --debug /node-api/bin/node-api.js
#command: node-debug /node-api/bin/node-api.js
#command: nodemon --debug /node-api/node-api.js --watch /node-api
tty: true
stdin_open: true
networks:
- mindnet
environment:
- NODE_ENV=development
nginx:
restart: always
build:
context: ./nginx
dockerfile: ./Dockerfile
ports:
- "80:80"
container_name: nginx
links:
# nginx has to link to flask-api (not vice-versa) so that nginx/sites-enabled/default has access to flask-api by service name (acts as host dns).
# each docker container has a seperate ip address below the docker-machine host, so you have to link containers to correctly pass to upstream flask port
- flask-api:flask-api
- node-api:node-api
tty: true
stdin_open: true
networks:
- mindnet
networks:
mindnet:
driver: bridge