-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yaml
56 lines (50 loc) · 978 Bytes
/
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
version: '3'
services:
app:
build:
context: node
container_name: app
networks:
- node-network
entrypoint: dockerize -wait tcp://db:3306 -timeout 20s docker-entrypoint.sh
command: node ./node/index.js
volumes:
- .:/usr/src/app
- exclude:/usr/src/app/node_modules
tty: true
ports:
- "3000:3000"
depends_on:
- db
db:
image: mysql:5.7
command: --innodb-use-native-aio=0
container_name: db
ports:
- "3306:3306"
restart: always
tty: true
volumes:
- ./mysql:/var/lib/mysql
environment:
MYSQL_DATABASE: nodedb
MYSQL_ROOT_PASSWORD: root
MYSQL_ROOT_HOST: "%"
networks:
- node-network
nginx:
restart: always
build:
context: nginx
container_name: nginx
ports:
- "8080:80"
networks:
- node-network
depends_on:
- app
networks:
node-network:
driver: bridge
volumes:
exclude: