From a6190fe29dceb97e7d1640850b7902db39662793 Mon Sep 17 00:00:00 2001 From: Jack Kawell Date: Tue, 7 Dec 2021 14:55:19 -0700 Subject: [PATCH 1/2] Add init volume to database --- docker-compose.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/docker-compose.yml b/docker-compose.yml index 56b33aa1..b161eccc 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -11,6 +11,7 @@ services: - MARIADB_DATABASE=${MARIADB_DATABASE:-darkflame} volumes: - database:/var/lib/mysql + - migrations/dlu:/docker-entrypoint-initdb.d networks: - darkflame From b1e700e2a2431238e16a6b96bc7c5c523d792ba8 Mon Sep 17 00:00:00 2001 From: Jack Kawell Date: Tue, 7 Dec 2021 14:56:56 -0700 Subject: [PATCH 2/2] Removed db migrations from script --- docker/start_server.sh | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/docker/start_server.sh b/docker/start_server.sh index 5797313d..12ea99ef 100644 --- a/docker/start_server.sh +++ b/docker/start_server.sh @@ -80,17 +80,6 @@ function fdb_to_sqlite() { ) } -function run_db_migrations() { - ( - cd /app/migrations/dlu - readarray -d '' entries < <(printf '%s\0' *.sql | sort -zV) - for entry in "${entries[@]}"; do - echo "Execute $entry" - mysql -h"$DATABASE_HOST" -P"$DATABASE_PORT" -u"$DATABASE_USER" -p"$DATABASE_PASSWORD" $DATABASE < $entry - done - ) -} - set_defaults check_sql_connection @@ -118,8 +107,6 @@ symlink_client_files fdb_to_sqlite -run_db_migrations - echo "Start MasterServer" ./MasterServer