-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathdocker-compose.deploy.yml
52 lines (46 loc) · 1.11 KB
/
docker-compose.deploy.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
version: '3.4'
services:
nginx:
image: "${CI_NGINX_IMAGE_WITH_TAG}"
ports:
- 80
networks:
nw_internal:
depends_on:
- mysql
volumes:
- "storage:/srv/storage:ro"
restart: always
labels:
docker-gen.host: ${SERVER_NAME}
php: &php-service
image: "${CI_APP_IMAGE_WITH_TAG}"
networks:
- nw_internal
env_file: .env
environment:
TRUSTED_PROXIES: "0.0.0.0/0"
volumes:
- "storage:/srv/storage:rw"
restart: always
spare:
<< : *php-service
mysql:
image: mysql:5.7.22
expose:
- 3306
environment:
MYSQL_ROOT_PASSWORD: "${ENV_database_root_password}"
MYSQL_DATABASE: "${ENV_database_name}"
MYSQL_USER: "${ENV_database_user}"
MYSQL_PASSWORD: "${ENV_database_password}"
networks:
- nw_internal
volumes:
- database:/var/lib/mysql
restart: always
volumes:
database:
storage:
networks:
nw_internal: