-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yaml
106 lines (101 loc) · 1.94 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
version: "3"
services:
mysql_pizzaria:
image: mysql:5.6
ports:
- "3306:3306"
expose:
- 3306
volumes:
- ./docker/data/db:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=123456
- MYSQL_DATABASE=pizzaria
web_pizzaria:
logging:
driver: "json-file"
options:
max-size: "200k"
max-file: "10"
image: nginx
restart: always
volumes:
- .:/app
ports:
- 81:80
expose:
- "81"
links:
- app_pizzaria
depends_on:
- app_pizzaria
networks:
- default
environment:
- VIRTUAL_HOST=app_pizzaria
app_pizzaria:
logging:
driver: "json-file"
options:
max-size: "200k"
max-file: "10"
build: .
command: npm start
restart: always
depends_on:
- mysql_pizzaria
- redis_pizzaria
ports:
- "3333:3333"
expose:
- "3333"
networks:
- default
environment:
- DB_HOST=mysql_pizzaria
- DB_PORT=3306
- DB_USER=root
- DB_PASSWORD=123456
- DB_DATABASE=pizzaria
- DB_CONNECTION=mysql
- REDIS_HOST=redis_pizzaria
- REDIS_CONNECTION=local
env_file:
- ./api.env
kue_pizzaria:
logging:
driver: "json-file"
options:
max-size: "200k"
max-file: "10"
build: .
restart: always
depends_on:
- redis_pizzaria
- app_pizzaria
- web_pizzaria
networks:
- default
volumes:
- .:/app
environment:
- REDIS_HOST=redis_pizzaria
- REDIS_CONNECTION=local
- REDIS_PORT=32768
env_file:
- ./api.env
command: npm run kue
redis_pizzaria:
restart: always
image: "redis:alpine"
networks:
- default
ports:
- "32768:32768"
volumes:
- ./docker/data/redis:/data
expose:
- 32768
entrypoint: redis-server --port 32768 --appendonly yes
volumes:
db-data: