mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2025-11-29 17:38:24 +08:00
* Remove .dist file requirement * Remove unnecessary string cast * Add required variables for CI build configs * More required variables * Add some more default variables to reduce log output * One last default value to cut down log spam * Rewrite conf file bash script This should use the standard .dest file as a template * Change dir we copy the dest files from * actually use the correct file name * need to use double quotes for variables * add missing username * set the correct datadir * Attempt to fix dbimport Co-authored-by: Foereaper <foereaper@elunatech.com>
15 lines
617 B
Bash
15 lines
617 B
Bash
APP_NAME=$1
|
|
CONFIG_FOLDER=${2:-"etc"}
|
|
BIN_FOLDER=${3-"bin"}
|
|
MYSQL_ROOT_PASSWORD=${4:-""}
|
|
|
|
# copy dist files to conf files
|
|
cp ./env/dist/$CONFIG_FOLDER/$APP_NAME.conf.dist ./env/dist/$CONFIG_FOLDER/$APP_NAME.conf
|
|
|
|
# replace login info
|
|
sed -i "s/127.0.0.1;3306;acore;acore/localhost;3306;root;$MYSQL_ROOT_PASSWORD/" ./env/dist/$CONFIG_FOLDER/$APP_NAME.conf
|
|
|
|
if [[ $APP_NAME == "worldserver" ]]; then
|
|
sed -i 's/DataDir = \".\"/DataDir = \".\/data"/' ./env/dist/$CONFIG_FOLDER/$APP_NAME.conf
|
|
git clone --depth=1 --branch=master --single-branch https://github.com/ac-data/ac-data.git ./env/dist/$BIN_FOLDER/data
|
|
fi |