mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2025-11-29 17:38:24 +08:00
## ⚠️ATTENTION! ⚠️ Upgrading procedure: **Database:** After this PR will be merged you need to backup your DB first (you can use the db-assembler or any mysql client to generate the dump) and restore it after. The reason is that we use now docker named volumes instead of binded ones to improve performance. **Conf & client data**: if you use the default configuration, both the etc and the data folder are now available inside the **/env/docker**. Finally, you can cleanup the /docker folder previously used by our system. ## Changes Proposed: This PR will implement the [devcontainer ](https://code.visualstudio.com/docs/remote/containers) feature for VSCode. Allowing us to develop and debug directly within the container in the same way on all OSes. * Implemented support for vscode dev-container feature by remote-extension suite * Docker performance optimizations for MacOS and non-linux hosts * Bash system improvements * Implemented first command using Deno runtime environment (typescript) and [commander.js] * Implemented wait mechanism for db_assembler * Implemented db migration command * possibility to run the authserver and worldserver with GDB using the integrated simple-restarter * Implemented docker multi-stage mechanism to use one single Dockerfile for all the services * client-data downloader now creates a placeholder to avoid downloading the same version of data files multiple times * deployment of pre-compiled docker images on [docker hub](https://hub.docker.com/u/acore), you can test them [here](https://github.com/azerothcore/acore-docker)
39 lines
994 B
Bash
39 lines
994 B
Bash
#!/bin/bash
|
|
#
|
|
# * Copyright (C) 2007 - 2015 Hyperweb2 All rights reserved.
|
|
# * GNU General Public License version 3; see www.hyperweb2.com/terms/
|
|
|
|
MYSQL="mysql"
|
|
MYSQLIMPORT="mysqlimport"
|
|
MYSQLDUMP="mysqldump"
|
|
DUMPPARSER=$MT_DIR"/bin/dump-parser"
|
|
|
|
if [[ $(uname -s) == "Darwin" ]]; then
|
|
DUMPPARSER=$MT_DIR"/bin/dump-parser-mac"
|
|
fi;
|
|
|
|
#empty for bash commands
|
|
WIN_BIN=0
|
|
command -v mysql >/dev/null 2>&1 || { WIN_BIN=1; }
|
|
command -v mysqlimport >/dev/null 2>&1 || { WIN_BIN=1; }
|
|
command -v mysqldump >/dev/null 2>&1 || { WIN_BIN=1; }
|
|
|
|
WIN_BIN=1
|
|
if [[ $(uname -s) == "Linux" ]] || [[ $(uname -s) == "Darwin" ]]; then
|
|
WIN_BIN=0
|
|
else
|
|
WIN_BIN=1
|
|
fi;
|
|
|
|
if (($WIN_BIN != 0)); then
|
|
MYSQL=$MT_DIR"/bin/$MYSQL"
|
|
MYSQLIMPORT=$MT_DIR"/bin/$MYSQLIMPORT"
|
|
MYSQLDUMP=$MT_DIR"/bin/$MYSQLDUMP"
|
|
fi;
|
|
|
|
OPTS=
|
|
[ ! -z "$MYSQL_USER" ] && OPTS+=" -u $MYSQL_USER"
|
|
[ ! -z "$MYSQL_PASS" ] && OPTS+=" -p$MYSQL_PASS"
|
|
[ ! -z "$MYSQL_HOST" ] && OPTS+=" -h $MYSQL_HOST"
|
|
[ ! -z "$MYSQL_SOCK" ] && OPTS+=" -S $MYSQL_SOCK"
|