-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-stack.yml
64 lines (58 loc) · 1.26 KB
/
docker-stack.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
version: "3.9"
services:
php:
image: ${DOCKER_REGISTRY}/infection-playground-php:latest
depends_on:
- db
secrets:
- mysql_password
networks:
- db
- php
environment:
- APP_ENV=prod
- APP_SECRET=${APP_SECRET}
- DATABASE_NAME=${DATABASE_NAME}
- DATABASE_USER=${DATABASE_USER}
- DATABASE_PASSWORD_FILE=/run/secrets/mysql_password
web:
image: ${DOCKER_REGISTRY}/infection-playground-nginx:latest
depends_on:
- php
networks:
- php
secrets:
- ssl_certificate
- ssl_key
ports:
- "443:443"
db:
image: mysql:5.7
ports:
- "3333:3306"
secrets:
- mysql_root_password
- mysql_password
environment:
- MYSQL_ROOT_PASSWORD_FILE=/run/secrets/mysql_root_password
- MYSQL_DATABASE=${DATABASE_NAME}
- MYSQL_USER=${DATABASE_USER}
- MYSQL_PASSWORD_FILE=/run/secrets/mysql_password
networks:
- db
volumes:
- db-data:/var/lib/mysql:rw
secrets:
ssl_certificate:
file: secrets/bundle.crt
ssl_key:
file: secrets/infection-php_dev.key
mysql_root_password:
file: secrets/mysql_root_password
mysql_password:
file: secrets/mysql_password
networks:
db:
php:
volumes:
db-data: