summaryrefslogtreecommitdiff
path: root/apps/ci
diff options
context:
space:
mode:
authorYehonal <yehonal.azeroth@gmail.com>2022-10-22 15:40:13 +0200
committerGitHub <noreply@github.com>2022-10-22 15:40:13 +0200
commit171df31196dc54b662ef7967d5b3d5ae3fc2eefc (patch)
tree1bb317c3b51de1b7549cdb5c1c598f2a50a5b517 /apps/ci
parentb35c907cde030f4ce4ee9162d016ba93f05d94ff (diff)
feat(CORE/bash): implemented acore dashboard for Windows (#13476)
+ implemented acore dashboard for windows + integrated acore dashboard for windows in our pipeline + implemented dry run for windows build + fixed permissions issue for all the operating systems + code clean
Diffstat (limited to 'apps/ci')
-rw-r--r--apps/ci/ci-dry-run.sh19
-rw-r--r--apps/ci/ci-gen-server-conf-files.sh21
-rw-r--r--apps/ci/ci-install.sh2
3 files changed, 25 insertions, 17 deletions
diff --git a/apps/ci/ci-dry-run.sh b/apps/ci/ci-dry-run.sh
index 2d234ea9a7..335d6a5352 100644
--- a/apps/ci/ci-dry-run.sh
+++ b/apps/ci/ci-dry-run.sh
@@ -2,25 +2,12 @@
set -e
+CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
+
# Start mysql
sudo systemctl start mysql
-APP_NAME=$1
-
-echo "LoginDatabaseInfo = \"localhost;3306;root;root;acore_auth\"" >> ./env/dist/etc/$APP_NAME.conf
-
-if [[ $APP_NAME != "authserver" ]]; then
- {
- echo "WorldDatabaseInfo = \"localhost;3306;root;root;acore_world\""
- echo "CharacterDatabaseInfo = \"localhost;3306;root;root;acore_characters\""
- } >> ./env/dist/etc/$APP_NAME.conf
-fi
-
-if [[ $APP_NAME == "worldserver" ]]; then
- echo "DataDir = \"../data/\"" >> ./env/dist/etc/$APP_NAME.conf
-
- git clone --depth=1 --branch=master --single-branch https://github.com/ac-data/ac-data.git ./env/dist/data
-fi
+source "$CURRENT_PATH/ci-gen-server-conf-files.sh" $1 "etc" "bin" "root"
(cd ./env/dist/bin/ && timeout 5m ./$APP_NAME -dry-run)
diff --git a/apps/ci/ci-gen-server-conf-files.sh b/apps/ci/ci-gen-server-conf-files.sh
new file mode 100644
index 0000000000..c6b7b1af75
--- /dev/null
+++ b/apps/ci/ci-gen-server-conf-files.sh
@@ -0,0 +1,21 @@
+APP_NAME=$1
+CONFIG_FOLDER=${2:-"etc"}
+BIN_FOLDER=${3-"bin"}
+MYSQL_ROOT_PASSWORD=${4:-""}
+
+
+echo "LoginDatabaseInfo = \"localhost;3306;root;$MYSQL_ROOT_PASSWORD;acore_auth\"" >> ./env/dist/$CONFIG_FOLDER/$APP_NAME.conf
+
+# worldserver or dbimport
+if [[ $APP_NAME != "authserver" ]]; then
+ {
+ echo "WorldDatabaseInfo = \"localhost;3306;root;$MYSQL_ROOT_PASSWORD;acore_world\""
+ echo "CharacterDatabaseInfo = \"localhost;3306;root;$MYSQL_ROOT_PASSWORD;acore_characters\""
+ } >> ./env/dist/$CONFIG_FOLDER/$APP_NAME.conf
+fi
+
+if [[ $APP_NAME == "worldserver" ]]; then
+ echo "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
diff --git a/apps/ci/ci-install.sh b/apps/ci/ci-install.sh
index 5ed81e26ce..c333d9685c 100644
--- a/apps/ci/ci-install.sh
+++ b/apps/ci/ci-install.sh
@@ -21,7 +21,7 @@ CONFIG_SH
time sudo apt-get update -y
# time sudo apt-get upgrade -y
-time sudo apt-get install -y git lsb-release sudo ccache
+time sudo apt-get install -y git lsb-release sudo
time ./acore.sh install-deps
case $COMPILER in