148 lines
5.5 KiB
Bash
Raw Permalink Normal View History

2018-02-26 21:40:08 +01:00
# absolute root path of your azerothcore repository
# It should not be modified if you don't really know what you're doing
SRCPATH="$AC_PATH_ROOT"
# absolute path where build files must be stored
BUILDPATH=${BUILDPATH:-"$AC_PATH_VAR/build/obj"}
Feat(Docker/bash): docker-compose system rework (#4488) ## ⚠️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)
2021-04-22 09:57:05 +02:00
# absolute path where azerothcore will be installed
# NOTE: on linux the binaries are stored in a subfolder (/bin)
# of the $BINPATH
BINPATH="$AC_PATH_ROOT/env/dist"
# bash fills it by default with your os type. No need to change it.
# Change it if you really know what you're doing.
# OSTYPE=""
# When using linux, our installer automatically get information about your distro
# using lsb_release. If your distro is not supported but it's based on ubuntu or debian,
# please change it to one of these values.
Feat(Docker/bash): docker-compose system rework (#4488) ## ⚠️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)
2021-04-22 09:57:05 +02:00
# OSDISTRO="ubuntu"
2016-07-28 13:33:10 +02:00
# absolute path where config. files must be stored
# default: the system will use binpath by default
# CONFDIR="$AC_PATH_ROOT/env/dist/etc/"
2016-07-28 13:33:10 +02:00
Feat(Docker/bash): docker-compose system rework (#4488) ## ⚠️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)
2021-04-22 09:57:05 +02:00
# absolute path where maps and client data will be downloaded
# by the AC dashboard
# default: the system will use binpath by default
# DATAPATH="$BINPATH/bin"
# DATAPATH_ZIP="$DATAPATH/data.zip"
Feat(Docker/bash): docker-compose system rework (#4488) ## ⚠️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)
2021-04-22 09:57:05 +02:00
# azerothcore's official remote source address to pull from
# by default git will fetch form the azrothcore remote
# You can change it to "origin" if you want to fetch/pull from the set remote
ORIGIN_REMOTE="https://github.com/azerothcore/azerothcore-wotlk.git"
# Branch configuration for the installer to pull from.
# By default git will select the current working branch
# You can set it to "master" if you want the latest updates
INSTALLER_PULL_FROM=
2016-07-28 13:33:10 +02:00
##############################################
#
# COMPILER_CONFIGURATIONS
#
##############################################
# Set preferred compilers.
# To use gcc (not suggested) instead of clang change in:
# CCOMPILERC="/usr/bin/gcc"
# CCOMPILERCXX="/usr/bin/g++"
#
2016-08-20 09:49:55 +02:00
CCOMPILERC="/usr/bin/clang"
CCOMPILERCXX="/usr/bin/clang++"
2016-07-28 13:33:10 +02:00
# how many thread must be used for compilation ( leave zero to use all available )
MTHREADS=${MTHREADS:-0}
2016-07-28 13:33:10 +02:00
# enable/disable warnings during compilation
CWARNINGS=ON
2016-07-28 13:33:10 +02:00
# enable/disable some debug informations ( it's not a debug compilation )
2016-08-15 23:59:30 +02:00
CDEBUG=OFF
Feat(Docker/bash): docker-compose system rework (#4488) ## ⚠️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)
2021-04-22 09:57:05 +02:00
# specify compilation type:
# * Release: high optimization level, no debug info, code or asserts.
# * Debug: No optimization, asserts enabled, [custom debug (output) code enabled],
# debug info included in executable (so you can step through the code with a
# debugger and have address to source-file:line-number translation).
# * RelWithDebInfo: optimized, *with* debug info, but no debug (output) code or asserts.
# * MinSizeRel: same as Release but optimizing for size rather than speed.
CTYPE=${CTYPE:-Release}
2016-07-28 13:33:10 +02:00
# compile scripts
CSCRIPTS=${CSCRIPTS:-static}
# compile modules
CMODULES=${CMODULES:-static}
# compile unit tests
CBUILD_TESTING=OFF
2016-07-28 13:33:10 +02:00
# use precompiled headers ( fatest compilation but not optimized if you change headers often )
CSCRIPTPCH=${CSCRIPTPCH:-ON}
CCOREPCH=${CCOREPCH:-ON}
# build apps list variable
CAPPS_BUILD=${CAPPS_BUILD:-all}
# build tools list variable
CTOOLS_BUILD=${CTOOLS_BUILD:-none}
# build apps list
CBUILD_APPS_LIST=${CBUILD_APPS_LIST:-''}
# build tools list
CBUILD_TOOLS_LIST=${CBUILD_TOOLS_LIST:-''}
# you can add your custom definitions here ( -D )
2021-07-15 04:47:40 +07:00
# example: CCUSTOMOPTIONS=" -DWITH_PERFTOOLS=ON
#
CCUSTOMOPTIONS=${CCUSTOMOPTIONS:-''}
# Enable ccache to speedup
# recompilations
#
AC_CCACHE=${AC_CCACHE:-false}
export CCACHE_DIR=${CCACHE_DIR:-"$AC_PATH_VAR/ccache"}
2016-07-28 13:33:10 +02:00
##############################################
#
# GOOGLE PERF TOOLS
#
# Repository: https://github.com/gperftools/gperftools#readme
# Documentation: https://gperftools.github.io/gperftools/
#
# Install (Ubuntu):
# sudo apt-get install google-perftools libgoogle-perftools-dev
# Note: dependencies above are already installed in docker
#
# Usage:
# 1. To enable the gperftools you need to compile with the -DWITH_PERFTOOLS=ON compiler flag. You can use CCUSTOMOPTIONS above to set it for the dashboard compiler
# 2. Configure the variable below accordingly to your needs
# 3. run the worldserver with the "./acore.sh run-worldserver"
# 4. run "killall -12 worldserver" This command will start the monitoring process. Run "killall -12 worldserver" again to stop the process when you want
# 5. At this time you will have the .prof file ready in the folder configured below.
# Run "google-pprof --callgrind <path/of/worldserver/bin> </path/of/prof/file>" This will generate a callgrind file that can be read with
# QCacheGrind, KCacheGrind and any other compatible tools
#
##############################################
# files used by gperftools to store monitored information
export CPUPROFILE=${CPUPROFILE:-"$BINPATH/logs/worldserver-cpu.prof"}
# heap profile is disabled by default. Uncomment this line to enable it
# export HEAPPROFILE=${HEAPPROFILE:-"$BINPATH/logs/worldserver-heap.prof"}
# signal to send to the kill command to start/stop the profiling process. kill -12
export CPUPROFILESIGNAL=${CPUPROFILESIGNAL:-12}
# How many interrupts/second the cpu-profiler samples.
#export CPUPROFILE_FREQUENCY=${CPUPROFILESIGNAL:-100}
# If set to any value (including 0 or the empty string), use ITIMER_REAL instead of ITIMER_PROF to gather profiles.
# In general, ITIMER_REAL is not as accurate as ITIMER_PROF, and also interacts badly with use of alarm(),
# so prefer ITIMER_PROF unless you have a reason prefer ITIMER_REAL.
#export CPUPROFILE_REALTIME=${CPUPROFILE_REALTIME}
# Other values for HEAPCHECK: minimal, normal (equivalent to "1"), strict, draconian
#export HEAPCHECK=${HEAPCHECK:-normal}
2016-07-28 13:33:10 +02:00