-
Notifications
You must be signed in to change notification settings - Fork 52
/
docker-compose.mariadb.yml
68 lines (64 loc) · 1.85 KB
/
docker-compose.mariadb.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
version: '3.8'
volumes:
ddon-server-mariadb-volume:
networks:
ddon-network:
services:
app:
container_name: ddon-server
build:
context: .
args:
- RUNTIME=${RUNTIME}
restart: no
ports:
# Game server
- "52000:52000"
# Web server
- "52099:52099"
# Login server
- "52100:52100"
environment:
- DB_TYPE=mariadb
- DB_DATABASE=mariadb
- DB_FOLDER=/var/ddon/server/Files/Database
- DB_HOST=db
- DB_USER=admin
- DB_PASS=admin
- DB_PORT=3306
- DB_WIPE_ON_STARTUP=false
volumes:
- ./Arrowgene.Ddon.config.mariadb.local_dev.json:/var/ddon/server/Files/Arrowgene.Ddon.config.json:ro
- ./Arrowgene.Ddon.Shared/Files/Assets:/var/ddon/server/Files/Assets:ro
networks:
- ddon-network
# Workaround: cli expects to be able to process keyboard input
tty: true
depends_on:
db:
condition: service_healthy
command: /var/ddon/server/Arrowgene.Ddon.Cli server start
db:
container_name: ddon-db
image: mariadb:11
ports:
# Database
- "3306:3306"
restart: no
volumes:
- ddon-server-mariadb-volume:/var/lib/mysql
- $PWD/deploy/mariadb/mariadb.cnf:/etc/mysql/mariadb.conf.d/mariadb.cnf:ro
networks:
- ddon-network
environment:
- MARIADB_USER=admin
- MARIADB_ROOT_PASSWORD=admin
- MARIADB_PASSWORD=admin
- MARIADB_DATABASE=mariadb
- LANG=C.UTF_8
command: ["--character-set-server=utf8mb4", "--collation-server=utf8mb4_unicode_ci"]
healthcheck:
test: ["CMD-SHELL", "mariadb --defaults-file=/var/lib/mysql/.my-healthcheck.cnf --skip-column-names -h localhost -e \"select 1 from information_schema.ENGINES WHERE ENGINE='InnoDB' AND support in ('YES', 'DEFAULT', 'ENABLED')\""]
interval: 3s
timeout: 3s
retries: 10