-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathcompose.yaml.example
More file actions
244 lines (239 loc) · 13.9 KB
/
compose.yaml.example
File metadata and controls
244 lines (239 loc) · 13.9 KB
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
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
services:
database:
image: ghcr.io/mserajnik/vmangos-database
restart: unless-stopped
# The healthcheck determines if the container is working as expected; if
# the healthcheck fails it causes a restart of the container. The default
# parameters here should work fine on most systems, but if you experience
# any issues, you might want to adjust them. In particular, the initial
# database creation might take a while and you may want to set
# `start_period` even higher if you notice that the container gets
# restarted before the initialization finishes.
healthcheck:
test: ['CMD', 'healthcheck.sh', '--connect', '--innodb_initialized']
interval: 1m
timeout: 3s
retries: 5
start_period: 10m # This is set relatively high to take the initial database creation into account; adjust as required.
volumes:
- vmangos-database:/var/lib/mysql
- ./storage/database/custom-sql:/sql/custom:ro
# Mount an SQL file as `/sql/world-new.sql` to force the re-creation of
# the world database (with the contents of the mounted file); make sure
# to remove this bind mount again before you restart the database the
# next time or it will continue to re-create the database each time you
# restart.
# This can be used to update to a world database dump newer than
# `world_full_14_june_2021`; however, this should not be necessary as the
# database migrations will keep it up to date anyway (and thus, a newer
# dump would only reduce the time of the initial creation of a fresh
# database because it would cause potentially lengthy migrations to get
# skipped).
# Therefore, this option is mainly here to have it available in case it
# becomes necessary or desirable to re-create the world database (e.g.,
# to cleanly get rid of any custom changes you may have made).
# - /path/to/new/world.sql:/sql/world-new.sql:ro
environment:
- TZ=Etc/UTC # Change this to your desired time zone (usually you want to match your host system's time zone).
- MARIADB_USER=mangos # Specifies the name for the database user utilized by VMaNGOS (must match the credentials in the VMaNGOS configuration files); please note that the name cannot be changed using this environment variable after the initial startup.
- MARIADB_PASSWORD=mangos # Specifies the password for the database user utilized by VMaNGOS (must match the credentials in the VMaNGOS configuration files); please note that the password cannot be changed using this environment variable after the initial startup.
- MARIADB_ROOT_PASSWORD=password # Specifies the password for the database's `root` user (not used by VMaNGOS itself, only for database creation/updates); please note that the password cannot be changed using this environment variable after the initial startup.
# Only a subset covering the most important realmlist parameters is
# exposed in this configuration file. Altering them here after the
# database has been created will _not_ update them, but you can always
# change them (and the other parameters not exposed here) manually in the
# database at any point (see the `phpmyadmin` service further below).
- VMANGOS_REALMLIST_NAME=VMaNGOS # Sets the name of the realm as it appears in the selection list and the character screen.
- VMANGOS_REALMLIST_ADDRESS=127.0.0.1 # Sets the LAN or WAN address of the realm; this can also be a domain name.
- VMANGOS_REALMLIST_PORT=8085 # Sets the port of the realm; changing this means it also needs to be changed in other places.
- VMANGOS_REALMLIST_ICON=1 # Sets the icon of the realm; 0 = Normal, 1 = PvP, 6 = RP, 8 = RP PVP.
- VMANGOS_REALMLIST_TIMEZONE=0 # Sets the time zone of the realm; some common values are: 2 = United States, 3 = Oceanic, 4 = Latin America, 8 = English, 9 = German, 10 = French, 11 = Spanish, 12 = Russian.
- VMANGOS_REALMLIST_ALLOWED_SECURITY_LEVEL=0 # Sets the minimum account security level required to log in to the realm; 0 = regular players.
# vmangos-deploy keeps track of certain, unusual VMaNGOS code changes
# (such as migration edits) that lead to a faulty (or out-of-sync) world
# database state when updating and would normally require manual
# intervention by you to rectify. In such cases, vmangos-deploy can
# automatically correct the state of your world database by re-creating
# it. It is strongly suggested to keep this feature enabled.
# If you do decide to disable it (by setting the following environment
# variable to `0`), you yourself are responsible for monitoring VMaNGOS
# for problematic code changes and taking appropriate actions (e.g.,
# manually triggering the re-creation of the world database by mounting a
# database dump, as described further above).
- VMANGOS_ENABLE_AUTOMATIC_WORLD_DB_CORRECTIONS=1
# If you want to make custom changes to the world database, it is
# recommended to do so using SQL files and placing them in
# `./storage/database/custom-sql` (a bind mount for this directory is
# configured out-of-the-box, as can be seen further above). This
# way, you can keep automatic world database corrections enabled without
# having to worry about your changes getting lost.
# By default, all SQL files (files with a `.sql` extension) in that
# directory will be processed during each startup in alphabetical order
# (after the world database has been created and updated with the latest
# migrations). Thus, the SQL statements in your files have to be
# idempotent (i.e., they can be processed multiple times without causing
# issues).
# If you want to disable this feature, set the following environment
# variable to `0`; while this also allows you to use SQL files containing
# non-idempotent statements (by setting the environment variable to `0`
# after the SQL files have been processed once), this is not
# recommended and should be avoided.
- VMANGOS_PROCESS_CUSTOM_SQL=1
realmd:
image: ghcr.io/mserajnik/vmangos-server:5875
# If you are using a Linux host and your user's UID and GID are not 1000,
# change these values to reflect your user's UID and GID. This will cause
# the user in the container to use the same UID and GID and prevent
# permission issues on the bind mounts.
# If you are on Windows or macOS, you can ignore this.
user: 1000:1000
command: realmd
depends_on:
- database
restart: unless-stopped
# The healthcheck determines if the container is working as expected; if
# the healthcheck fails it causes a restart of the container. The default
# parameters here should work fine on most systems, but if you experience
# any issues, you might want to adjust them. In particular, the initial
# database creation might take a while and you may want to set
# `start_period` even higher if you notice that the container gets
# restarted before the initialization finishes.
healthcheck:
test: ['CMD', 'nc', '-z', 'localhost', '3724']
interval: 1m
timeout: 3s
retries: 5
start_period: 10m # This is set relatively high to take the initial database creation into account; adjust as required.
ports:
- 3724:3724
volumes:
- ./config/realmd.conf:/opt/vmangos/config/realmd.conf:ro
- ./storage/realmd/logs:/opt/vmangos/storage/logs
environment:
- TZ=Etc/UTC # Change this to your desired time zone (usually you want to match your host system's time zone).
- WAIT_HOSTS=database:3306
- WAIT_TIMEOUT=600 # This should match `start_period` in the `healthcheck` section (in seconds).
mangosd:
image: ghcr.io/mserajnik/vmangos-server:5875
# If you are using a Linux host and your user's UID and GID are not 1000,
# change these values to reflect your user's UID and GID. This will cause
# the user in the container to use the same UID and GID and prevent
# permission issues on the bind mounts.
# If you are on Windows or macOS, you can ignore this.
user: 1000:1000
command: mangosd
tty: true
stdin_open: true
depends_on:
- database
restart: unless-stopped
# `stop_grace_period` configures how long Docker waits during shutdown
# before it kills the container. The Docker default is 10 seconds, which
# might be too short for VMaNGOS servers with larger populations to
# complete the shutdown tasks in time. Setting it to 2 minutes instead
# should be on the safe side and does not have any downsides except the
# longer wait time when the server actually hangs during shutdown. Feel
# free to adjust this value based on the actual shutdown duration you
# observe.
stop_grace_period: 2m
# The healthcheck determines if the container is working as expected; if
# the healthcheck fails it causes a restart of the container. The default
# parameters here should work fine on most systems, but if you experience
# any issues, you might want to adjust them. In particular, the initial
# database creation might take a while and you may want to set
# `start_period` even higher if you notice that the container gets
# restarted before the initialization finishes.
healthcheck:
test: ['CMD', 'nc', '-z', 'localhost', '8085']
interval: 1m
timeout: 3s
retries: 5
start_period: 10m # This is set relatively high to take the initial database creation into account; adjust as required.
ports:
- 8085:8085
# To enable SOAP API access, set `SOAP.Enabled` to `1` and make sure
# `SOAP.IP` is set to `0.0.0.0` and `SOAP.Port` to `7878` in your
# `./config/mangosd.conf`, then uncomment the following port mapping:
# - 7878:7878
# To enable RA, set `Ra.Enable` to `1` and make sure `Ra.IP` is set to
# `0.0.0.0` and `Ra.Port` to `3443` in your `./config/mangosd.conf`, then
# uncomment the following port mapping:
# - 3443:3443
volumes:
- ./config/mangosd.conf:/opt/vmangos/config/mangosd.conf:ro
- ./storage/mangosd/extracted-data:/opt/vmangos/storage/data:ro
- ./storage/mangosd/logs:/opt/vmangos/storage/logs
- ./storage/mangosd/honor:/opt/vmangos/storage/honor
# To enable the usage of Warden, download the Warden modules from
# https://github.com/vmangos/warden_modules and place them into
# `./storage/mangosd/warden-modules`.
# Note that using HermesProxy (or projects derived from it) to connect
# `1.14.x` clients to VMaNGOS will likely not be possible (in a stable
# manner without getting kicked off the server) when Warden is enabled.
# Finally, uncomment the following bind mount and (optionally) adjust
# the Warden configuration in your `./config/mangosd.conf` (in
# particular, ensure that `Warden.ModuleDir` is set to
# `/opt/vmangos/storage/warden-modules`).
# - ./storage/mangosd/warden-modules:/opt/vmangos/storage/warden-modules
environment:
- TZ=Etc/UTC # Change this to your desired time zone (usually you want to match your host system's time zone).
- WAIT_HOSTS=database:3306
- WAIT_TIMEOUT=600 # This should match `start_period` in the `healthcheck` section (in seconds).
# # Optional:
# # Uncomment this service to enable periodic database backups.
# # The default configuration should work out of the box (unless you have
# # modified the `database` service configuration) and will create a backup
# # every day at 04:00 (change the `TIMEZONE` environment variable to your
# # desired time zone). Backups older than a week will automatically get
# # deleted.
# # Backups will be stored in `./storage/database/backups`.
# # See https://github.com/tiredofit/docker-db-backup#configuration for more
# # information.
# database-backup:
# image: tiredofit/db-backup
# depends_on:
# - database
# restart: unless-stopped
# volumes:
# - ./storage/database/backups:/backup
# environment:
# - TIMEZONE=Etc/UTC # Change this to your desired time zone (usually you want to match your host system's time zone).
# - CONTAINER_ENABLE_MONITORING=FALSE
# # If you are using a Linux host and your user's UID and GID are not 1000,
# # change these next two variables to reflect your user's UID and GID.
# # This will cause the user in the container to use the same UID and GID
# # and prevent permission issues on the bind mount.
# # If you are on Windows or macOS, you can ignore this.
# - USER_DBBACKUP=1000
# - GROUP_DBBACKUP=1000
# - DEFAULT_COMPRESSION=GZ
# - DEFAULT_BACKUP_INTERVAL=1440 # How often to run the backup in minutes; 1440 means once per day.
# - DEFAULT_BACKUP_BEGIN=0400 # When to start the backup; 0400 means it starts at 04:00.
# - DEFAULT_CLEANUP_TIME=10080 # How old backups have to be to get deleted; 10080 means backups older than a week get deleted.
# - DB01_TYPE=mariadb
# - DB01_HOST=database
# - DB01_NAME=characters,realmd # Which databases should be backed up.
# - DB01_USER=root
# - DB01_PASS=password # Must match the `MARIADB_ROOT_PASSWORD` environment variable of the `database` service.
# # Optional:
# # Uncomment this service to run phpMyAdmin, a web-based MySQL/MariaDB
# # database administration tool.
# # This can be useful to manage accounts, make changes to the realm
# # configuration etc.
# # With the default configuration, you should be able to open
# # http://localhost:8080 in your browser and have access to all of the
# # databases VMaNGOS uses.
# phpmyadmin:
# image: phpmyadmin
# depends_on:
# - database
# restart: unless-stopped
# ports:
# - 8080:80
# environment:
# - PMA_HOST=database
# - PMA_PORT=3306
# - PMA_USER=root
# - PMA_PASSWORD=password # Must match the `MARIADB_ROOT_PASSWORD` environment variable of the `database` service.
volumes:
vmangos-database: