~mser/vmangos-docker

bc2bc18b72d45d684157b501c54e39332113de1c — Michael Serajnik 5 months ago 3f3403b
Handle potential logs database migrations
3 files changed, 6 insertions(+), 0 deletions(-)

M 00-update-including-world-database-import.sh
M 00-update.sh
M docker/database/generate-db-2.sh
M 00-update-including-world-database-import.sh => 00-update-including-world-database-import.sh +2 -0
@@ 93,6 93,8 @@ docker-compose exec vmangos_database sh -c \
  '[ -e /opt/vmangos/sql/migrations/characters_db_updates.sql ] && mysql -u root -p$MYSQL_ROOT_PASSWORD characters < /opt/vmangos/sql/migrations/characters_db_updates.sql'
docker-compose exec vmangos_database sh -c \
  '[ -e /opt/vmangos/sql/migrations/logon_db_updates.sql ] && mysql -u root -p$MYSQL_ROOT_PASSWORD realmd < /opt/vmangos/sql/migrations/logon_db_updates.sql'
docker-compose exec vmangos_database sh -c \
  '[ -e /opt/vmangos/sql/migrations/logs_db_updates.sql ] && mysql -u root -p$MYSQL_ROOT_PASSWORD realmd < /opt/vmangos/sql/migrations/logs_db_updates.sql'

echo "[VMaNGOS]: Recreating other containers..."


M 00-update.sh => 00-update.sh +2 -0
@@ 101,6 101,8 @@ docker-compose exec vmangos_database sh -c \
  '[ -e /opt/vmangos/sql/migrations/characters_db_updates.sql ] && mysql -u root -p$MYSQL_ROOT_PASSWORD characters < /opt/vmangos/sql/migrations/characters_db_updates.sql'
docker-compose exec vmangos_database sh -c \
  '[ -e /opt/vmangos/sql/migrations/logon_db_updates.sql ] && mysql -u root -p$MYSQL_ROOT_PASSWORD realmd < /opt/vmangos/sql/migrations/logon_db_updates.sql'
docker-compose exec vmangos_database sh -c \
  '[ -e /opt/vmangos/sql/migrations/logs_db_updates.sql ] && mysql -u root -p$MYSQL_ROOT_PASSWORD realmd < /opt/vmangos/sql/migrations/logs_db_updates.sql'

echo "[VMaNGOS]: Recreating other containers..."


M docker/database/generate-db-2.sh => docker/database/generate-db-2.sh +2 -0
@@ 21,6 21,8 @@ echo "[VMaNGOS]: Importing database updates..."
  mysql -u root -p$MYSQL_ROOT_PASSWORD characters < /opt/vmangos/sql/migrations/characters_db_updates.sql
[ -e /opt/vmangos/sql/migrations/logon_db_updates.sql ] && \
  mysql -u root -p$MYSQL_ROOT_PASSWORD realmd < /opt/vmangos/sql/migrations/logon_db_updates.sql
[ -e /opt/vmangos/sql/migrations/logs_db_updates.sql ] && \
  mysql -u root -p$MYSQL_ROOT_PASSWORD realmd < /opt/vmangos/sql/migrations/logs_db_updates.sql

echo "[VMaNGOS]: Upgrading mysql..."
mysql_upgrade -u root -p$MYSQL_ROOT_PASSWORD