forked from Akkadius/akk-stack
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
211 lines (194 loc) · 5.53 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
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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
networks:
backend:
driver: ${NETWORKS_DRIVER}
volumes:
build-cache:
spire-assets:
eqemu-var-log:
mariadb-var-log:
services:
#############################################
# eqemu server
#############################################
eqemu-server:
restart: unless-stopped
image: akkadius/eqemu-server:v15
volumes:
- ./server:/home/eqemu/server:delegated
- ./code:/home/eqemu/code:delegated
- ./assets:/home/eqemu/assets:delegated
- build-cache:/home/eqemu/.ccache/
- spire-assets:/home/eqemu/.cache/
- eqemu-var-log:/var/log/
ports:
- ${IP_ADDRESS}:2222:22/tcp
- ${IP_ADDRESS}:2222:22/udp
- ${IP_ADDRESS}:3000-3010:3000-3010
- ${IP_ADDRESS}:8080:8080
- ${IP_ADDRESS}:9001:9001/tcp
- ${IP_ADDRESS}:9001:9001/udp
- ${IP_ADDRESS}:9000:9000/tcp
- ${IP_ADDRESS}:9000:9000/udp
- ${IP_ADDRESS}:5999:5999/tcp
- ${IP_ADDRESS}:5999:5999/udp
- ${IP_ADDRESS}:5998:5998/tcp
- ${IP_ADDRESS}:5998:5998/udp
- ${IP_ADDRESS}:6000:6000/tcp
- ${IP_ADDRESS}:7778:7778/tcp
- ${IP_ADDRESS}:7778:7778/udp
- ${IP_ADDRESS}:7000-${PORT_RANGE_HIGH}:7000-${PORT_RANGE_HIGH}/tcp
- ${IP_ADDRESS}:7000-${PORT_RANGE_HIGH}:7000-${PORT_RANGE_HIGH}/udp
environment:
- SPIRE_PORT=${SPIRE_PORT:-3000}
- SPIRE_ADMIN_PASSWORD=${SPIRE_ADMIN_PASSWORD:-}
- SERVER_PASSWORD=${SERVER_PASSWORD}
- EQEMU_DB_PASSWORD=${MARIADB_PASSWORD}
- PEQ_EDITOR_PASSWORD=${PEQ_EDITOR_PASSWORD}
- IP_ADDRESS=${IP_ADDRESS}
- PORT_RANGE_HIGH=${PORT_RANGE_HIGH}
- TZ=${TZ:-US/Central}
tty: true
networks:
- backend
cap_add:
# This is needed for running perf traces
# - CAP_SYS_ADMIN
# For GDB traces but it has security implications
- SYS_PTRACE
cpu_shares: 900
depends_on:
- fail2ban
#############################################
# mariadb
#############################################
mariadb:
restart: unless-stopped
build:
context: ./containers/mariadb
args:
- INNODB_BUFFER_POOL_SIZE=${INNODB_BUFFER_POOL_SIZE:-256MB}
ports:
- ${IP_ADDRESS}:3306:3306
volumes:
- ${DATA_PATH_HOST}/mariadb:/var/lib/mysql:delegated
- mariadb-var-log:/var/log/mysql/
environment:
- MYSQL_DATABASE=${MARIADB_DATABASE}
- MYSQL_USER=${MARIADB_USER}
- MYSQL_PASSWORD=${MARIADB_PASSWORD}
- MYSQL_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD}
- MYSQL_ALLOW_EMPTY_PASSWORD=NO
- TZ=${TZ:-US/Central}
networks:
- backend
depends_on:
- fail2ban
#############################################
# fail2ban
#############################################
fail2ban:
restart: unless-stopped
build:
context: ./containers/fail2ban
network_mode: host
cap_add:
- NET_ADMIN
- NET_RAW
environment:
- F2B_LOG_LEVE=DEBUG
- F2B_DB_PURGE_AGE=30d
- F2B_MAX_RETRY=3
- F2B_ACTION=%(action_)s
- F2B_IPTABLES_CHAIN=DOCKER-USER
- TZ=${TZ:-US/Central}
volumes:
- /etc/localtime:/etc/localtime:ro
- /var/log:/var/log:ro
- eqemu-var-log:/eqemu/var/log/
- mariadb-var-log:/mariadb/var/log/mysql/
#############################################
# phpmyadmin
#############################################
phpmyadmin-proxy:
build: ./containers/http-proxy
restart: unless-stopped
ports:
- ${IP_ADDRESS}:8082:80
environment:
- BASIC_AUTH_USERNAME=${PHPMYADMIN_USERNAME}
- BASIC_AUTH_PASSWORD=${PHPMYADMIN_PASSWORD}
- PROXY_PASS=http://phpmyadmin
- TZ=${TZ:-US/Central}
networks:
- backend
phpmyadmin:
depends_on:
- phpmyadmin-proxy
restart: unless-stopped
image: phpmyadmin/phpmyadmin:latest
environment:
- PMA_HOST=mariadb
- PMA_USER=${MARIADB_USER}
- PMA_PASSWORD=${MARIADB_PASSWORD}
- TZ=${TZ:-US/Central}
networks:
- backend
#############################################
# peq editor
#############################################
peq-editor:
image: akkadius/peq-editor:latest
restart: unless-stopped
ports:
- ${IP_ADDRESS}:8081:80
volumes:
- ${DATA_PATH_HOST}/peq-editor:/var/www/html
environment:
DB_HOST: mariadb
DB_NAME: ${MARIADB_DATABASE}
DB_USER: ${MARIADB_USER}
DB_PASSWORD: ${MARIADB_PASSWORD}
TZ: ${TZ:-US/Central}
networks:
- backend
#############################################
# ftp
#############################################
ftp-quests:
image: stilliard/pure-ftpd
restart: unless-stopped
environment:
FTP_USER_UID: 1000
FTP_USER_GID: 1000
FTP_USER_NAME: quests
FTP_USER_PASS: ${FTP_QUESTS_PASSWORD}
FTP_USER_HOME: '/home/quests/'
FTP_MAX_CLIENTS: 25
FTP_PASSIVE_PORTS: '30000:30049'
PUBLICHOST: ${IP_ADDRESS}
TZ: ${TZ:-US/Central}
volumes:
- ./server/quests/:/home/quests/
ports:
- ${IP_ADDRESS}:21:21
- ${IP_ADDRESS}:30000-30049:30000-30049
networks:
- backend
#############################################
# backup
#############################################
backup-cron:
restart: unless-stopped
image: akkadius/eqemu-backup-cron:latest
build:
context: ./containers/backup-cron
hostname: backup-cron
tty: true
volumes:
- ./:/home/backup-cron/
environment:
TZ: America/Chicago
# HOST_NAME: ${HOSTNAME:-default}
# HOST_DIR: ${PWD}
networks:
- backend