forked from camilo/lhm
-
Notifications
You must be signed in to change notification settings - Fork 24
/
docker-compose.yml
60 lines (60 loc) · 1.4 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
services:
# Writer
mysql-1:
container_name: mysql-1
image: percona:5.7
platform: linux/amd64
command:
--server-id=1
--log-bin
--log-slave-updates=ON
--gtid-mode=ON
--enforce-gtid-consistency=ON
--read-only=OFF
--max-connections=1000
hostname: 'mysql-1'
volumes:
- ./scripts/mysql/writer:/docker-entrypoint-initdb.d
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_HOST: mysql-1
ports:
- "13006:3306"
# Reader
mysql-2:
container_name: mysql-2
image: percona:5.7
platform: linux/amd64
command:
--server-id=2
--log-bin
--log-slave-updates=ON
--gtid-mode=ON
--enforce-gtid-consistency=ON
--read-only=ON
--max-connections=1000
hostname: 'mysql-2'
volumes:
- ./scripts/mysql/reader:/docker-entrypoint-initdb.d
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_HOST: mysql-2
ports:
- "13007:3306"
# Proxysql
proxysql:
container_name: proxysql
image: proxysql/proxysql:2.0.11
volumes:
- ./scripts/proxysql/proxysql.cnf:/etc/proxysql.cnf
command: "proxysql -c /etc/proxysql.cnf -f --idle-threads"
ports:
- "13005:3306"
- "6032:6032"
toxiproxy:
container_name: toxiproxy
image: "ghcr.io/shopify/toxiproxy"
ports:
- "8474:8474"
- "22220:22220"
- "22222:22222"