forked from bubbajames-docker/sendy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
62 lines (57 loc) · 1.2 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
62
version: "3.7"
# Volumes for persisted data.
volumes:
data_sendy:
labels:
co.sendy.description: "Data volume for Sendy Database."
# Secret files so they're not exposed via 'docker inspect'
secrets:
db_password:
file: secrets/db_password
db_root_password:
file: secrets/db_root_password
services:
# Database: MySQL
db_sendy:
hostname: db_sendy
container_name: db_sendy
image: mysql:5.6
env_file:
- sendy.env
environment:
MYSQL_ROOT_PASSWORD_FILE: /run/secrets/db_root_password
secrets:
- db_root_password
- db_password
volumes:
- data_sendy:/var/lib/mysql
# WebApp: Apache2+PHP+Sendy
sendy:
hostname: sendy
container_name: sendy
depends_on:
- db_sendy
image: sendy:latest
build:
context: .
# Uncomment to enabled XDEBUG build
# target: debug
env_file:
- sendy.env
secrets:
- db_password
ports:
- 8080:80
# Load Balancer: HAProxy
load-balancer:
hostname: lb_sendy
container_name: lb_sendy
image: lb_sendy
build:
context: .
dockerfile: haproxy/Dockerfile
env_file:
- sendy.env
ports:
- 80:80
- 443:443