mirror of
https://github.com/uprightbass360/AzerothCore-RealmMaster.git
synced 2026-01-13 00:58:34 +00:00
fix: Keep source builds local and disable mod-pocket-portal
This commit is contained in:
@@ -106,8 +106,15 @@ compose(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
ensure_source_repo(){
|
ensure_source_repo(){
|
||||||
|
local module_playerbots
|
||||||
|
module_playerbots="$(read_env MODULE_PLAYERBOTS "0")"
|
||||||
|
local default_source="./source/azerothcore"
|
||||||
|
if [ "$module_playerbots" = "1" ]; then
|
||||||
|
default_source="./source/azerothcore-playerbots"
|
||||||
|
fi
|
||||||
|
|
||||||
local src_path
|
local src_path
|
||||||
src_path="$(read_env MODULES_REBUILD_SOURCE_PATH "./source/azerothcore")"
|
src_path="$(read_env MODULES_REBUILD_SOURCE_PATH "$default_source")"
|
||||||
if [[ "$src_path" != /* ]]; then
|
if [[ "$src_path" != /* ]]; then
|
||||||
src_path="$ROOT_DIR/$src_path"
|
src_path="$ROOT_DIR/$src_path"
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -228,8 +228,9 @@ execute_module_sql_scripts() {
|
|||||||
execute_module_sql "mod-TimeIsTime" "Time Is Time"
|
execute_module_sql "mod-TimeIsTime" "Time Is Time"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$MODULE_POCKET_PORTAL" = "1" ] && [ -d "mod-pocket-portal" ]; then
|
if [ "$MODULE_POCKET_PORTAL" = "1" ]; then
|
||||||
execute_module_sql "mod-pocket-portal" "Pocket Portal"
|
echo '⚠️ Skipping mod-pocket-portal SQL: module disabled until C++20 patch is applied.'
|
||||||
|
MODULE_POCKET_PORTAL=0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$MODULE_RANDOM_ENCHANTS" = "1" ] && [ -d "mod-random-enchants" ]; then
|
if [ "$MODULE_RANDOM_ENCHANTS" = "1" ] && [ -d "mod-random-enchants" ]; then
|
||||||
|
|||||||
@@ -117,6 +117,12 @@ if [ "$MODULE_TIME_IS_TIME" != "1" ] && [ -d "mod-TimeIsTime" ]; then
|
|||||||
rm -rf mod-TimeIsTime
|
rm -rf mod-TimeIsTime
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$MODULE_POCKET_PORTAL" = "1" ]; then
|
||||||
|
echo '⚠️ mod-pocket-portal is temporarily disabled (requires C++20 <format>). Skipping until patched.'
|
||||||
|
echo ' Apply the std::format -> SendSystemMessage fix before re-enabling this module.'
|
||||||
|
MODULE_POCKET_PORTAL=0
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$MODULE_POCKET_PORTAL" != "1" ] && [ -d "mod-pocket-portal" ]; then
|
if [ "$MODULE_POCKET_PORTAL" != "1" ] && [ -d "mod-pocket-portal" ]; then
|
||||||
echo 'Removing mod-pocket-portal (disabled)...'
|
echo 'Removing mod-pocket-portal (disabled)...'
|
||||||
rm -rf mod-pocket-portal
|
rm -rf mod-pocket-portal
|
||||||
@@ -224,13 +230,12 @@ echo 'Installing enabled modules...'
|
|||||||
# Install Playerbots if enabled
|
# Install Playerbots if enabled
|
||||||
if [ "$MODULE_PLAYERBOTS" = "1" ] && [ ! -d "mod-playerbots" ]; then
|
if [ "$MODULE_PLAYERBOTS" = "1" ] && [ ! -d "mod-playerbots" ]; then
|
||||||
echo '🤖 Installing mod-playerbots...'
|
echo '🤖 Installing mod-playerbots...'
|
||||||
echo ' 📖 Project: https://github.com/liyunfan1223/mod-playerbots'
|
echo ' 📖 Project: https://github.com/uprightbass360/mod-playerbots'
|
||||||
echo ' 🚨 CRITICAL: REQUIRES Custom AzerothCore branch (liyunfan1223/azerothcore-wotlk/tree/Playerbot)'
|
echo ' 🚨 CRITICAL: REQUIRES Custom AzerothCore branch (uprightbass360/azerothcore-wotlk-playerbots/tree/Playerbot)'
|
||||||
echo ' 🚨 INCOMPATIBLE with standard AzerothCore - module will not function properly'
|
echo ' 🚨 INCOMPATIBLE with standard AzerothCore - module will not function properly'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 📋 POST-INSTALL: Requires manual account/character configuration'
|
echo ' 📋 POST-INSTALL: Requires manual account/character configuration'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
git clone https://github.com/uprightbass360/mod-playerbots.git mod-playerbots
|
||||||
git clone https://github.com/liyunfan1223/mod-playerbots.git mod-playerbots
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Install AOE Loot if enabled
|
# Install AOE Loot if enabled
|
||||||
@@ -239,7 +244,6 @@ if [ "$MODULE_AOE_LOOT" = "1" ] && [ ! -d "mod-aoe-loot" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/azerothcore/mod-aoe-loot'
|
echo ' 📖 Project: https://github.com/azerothcore/mod-aoe-loot'
|
||||||
echo ' ℹ️ Allows looting multiple corpses with one action'
|
echo ' ℹ️ Allows looting multiple corpses with one action'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-aoe-loot.git mod-aoe-loot
|
git clone https://github.com/azerothcore/mod-aoe-loot.git mod-aoe-loot
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -249,7 +253,6 @@ if [ "$MODULE_LEARN_SPELLS" = "1" ] && [ ! -d "mod-learn-spells" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/azerothcore/mod-learn-spells'
|
echo ' 📖 Project: https://github.com/azerothcore/mod-learn-spells'
|
||||||
echo ' ℹ️ Automatically teaches class spells on level up'
|
echo ' ℹ️ Automatically teaches class spells on level up'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-learn-spells.git mod-learn-spells
|
git clone https://github.com/azerothcore/mod-learn-spells.git mod-learn-spells
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -259,7 +262,6 @@ if [ "$MODULE_FIREWORKS" = "1" ] && [ ! -d "mod-fireworks-on-level" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/azerothcore/mod-fireworks-on-level'
|
echo ' 📖 Project: https://github.com/azerothcore/mod-fireworks-on-level'
|
||||||
echo ' ℹ️ Displays fireworks when players level up'
|
echo ' ℹ️ Displays fireworks when players level up'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-fireworks-on-level.git mod-fireworks-on-level
|
git clone https://github.com/azerothcore/mod-fireworks-on-level.git mod-fireworks-on-level
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -271,7 +273,6 @@ if [ "$MODULE_INDIVIDUAL_PROGRESSION" = "1" ] && [ ! -d "mod-individual-progress
|
|||||||
echo ' ✅ AUTO-CONFIG: Automatically sets EnablePlayerSettings=1 and DBC.EnforceItemAttributes=0'
|
echo ' ✅ AUTO-CONFIG: Automatically sets EnablePlayerSettings=1 and DBC.EnforceItemAttributes=0'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 📁 Optional client files available in optional/ directory'
|
echo ' 📁 Optional client files available in optional/ directory'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/ZhengPeiRu21/mod-individual-progression.git mod-individual-progression
|
git clone https://github.com/ZhengPeiRu21/mod-individual-progression.git mod-individual-progression
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -298,7 +299,6 @@ if [ "$MODULE_TRANSMOG" = "1" ] && [ ! -d "mod-transmog" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/azerothcore/mod-transmog'
|
echo ' 📖 Project: https://github.com/azerothcore/mod-transmog'
|
||||||
echo ' ℹ️ Allows appearance customization of equipment'
|
echo ' ℹ️ Allows appearance customization of equipment'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-transmog.git mod-transmog
|
git clone https://github.com/azerothcore/mod-transmog.git mod-transmog
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -319,7 +319,6 @@ if [ "$MODULE_SOLO_LFG" = "1" ] && [ ! -d "mod-solo-lfg" ]; then
|
|||||||
echo ' ℹ️ Allows dungeon finder for solo players and small groups'
|
echo ' ℹ️ Allows dungeon finder for solo players and small groups'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 💡 Pairs perfectly with mod-solocraft and mod-autobalance'
|
echo ' 💡 Pairs perfectly with mod-solocraft and mod-autobalance'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-solo-lfg.git mod-solo-lfg
|
git clone https://github.com/azerothcore/mod-solo-lfg.git mod-solo-lfg
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -369,7 +368,6 @@ if [ "$MODULE_ELUNA" = "1" ] && [ ! -d "mod-eluna" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/azerothcore/mod-eluna'
|
echo ' 📖 Project: https://github.com/azerothcore/mod-eluna'
|
||||||
echo ' ℹ️ Lua scripting engine for custom server functionality'
|
echo ' ℹ️ Lua scripting engine for custom server functionality'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-eluna.git mod-eluna
|
git clone https://github.com/azerothcore/mod-eluna.git mod-eluna
|
||||||
fi
|
fi
|
||||||
if [ "$MODULE_ARAC" = "1" ] && [ ! -d "mod-arac" ]; then
|
if [ "$MODULE_ARAC" = "1" ] && [ ! -d "mod-arac" ]; then
|
||||||
@@ -378,7 +376,6 @@ if [ "$MODULE_ARAC" = "1" ] && [ ! -d "mod-arac" ]; then
|
|||||||
echo ' ℹ️ All Races All Classes - Removes class restrictions'
|
echo ' ℹ️ All Races All Classes - Removes class restrictions'
|
||||||
echo ' 🚨 CRITICAL: Requires DBC file updates and client patch!'
|
echo ' 🚨 CRITICAL: Requires DBC file updates and client patch!'
|
||||||
echo ' 📋 POST-INSTALL: Apply Patch-A.MPQ to client WoW/Data/ directory'
|
echo ' 📋 POST-INSTALL: Apply Patch-A.MPQ to client WoW/Data/ directory'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/heyitsbench/mod-arac.git mod-arac
|
git clone https://github.com/heyitsbench/mod-arac.git mod-arac
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -387,11 +384,6 @@ if [ "$MODULE_TIME_IS_TIME" = "1" ] && [ ! -d "mod-TimeIsTime" ]; then
|
|||||||
git clone https://github.com/dunjeon/mod-TimeIsTime.git mod-TimeIsTime
|
git clone https://github.com/dunjeon/mod-TimeIsTime.git mod-TimeIsTime
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$MODULE_POCKET_PORTAL" = "1" ] && [ ! -d "mod-pocket-portal" ]; then
|
|
||||||
echo 'Installing mod-pocket-portal...'
|
|
||||||
git clone https://github.com/azerothcore/mod-pocket-portal.git mod-pocket-portal
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$MODULE_RANDOM_ENCHANTS" = "1" ] && [ ! -d "mod-random-enchants" ]; then
|
if [ "$MODULE_RANDOM_ENCHANTS" = "1" ] && [ ! -d "mod-random-enchants" ]; then
|
||||||
echo 'Installing mod-random-enchants...'
|
echo 'Installing mod-random-enchants...'
|
||||||
git clone https://github.com/azerothcore/mod-random-enchants.git mod-random-enchants
|
git clone https://github.com/azerothcore/mod-random-enchants.git mod-random-enchants
|
||||||
@@ -421,7 +413,6 @@ if [ "$MODULE_NPC_ENCHANTER" = "1" ] && [ ! -d "mod-npc-enchanter" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/azerothcore/mod-npc-enchanter'
|
echo ' 📖 Project: https://github.com/azerothcore/mod-npc-enchanter'
|
||||||
echo ' ℹ️ NPC that provides enchanting services'
|
echo ' ℹ️ NPC that provides enchanting services'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/azerothcore/mod-npc-enchanter.git mod-npc-enchanter
|
git clone https://github.com/azerothcore/mod-npc-enchanter.git mod-npc-enchanter
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -439,7 +430,6 @@ if [ "$MODULE_ASSISTANT" = "1" ] && [ ! -d "mod-assistant" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/noisiver/mod-assistant'
|
echo ' 📖 Project: https://github.com/noisiver/mod-assistant'
|
||||||
echo ' ℹ️ NPC (ID: 9000000) providing heirlooms, glyphs, gems, profession services'
|
echo ' ℹ️ NPC (ID: 9000000) providing heirlooms, glyphs, gems, profession services'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/noisiver/mod-assistant.git mod-assistant
|
git clone https://github.com/noisiver/mod-assistant.git mod-assistant
|
||||||
fi
|
fi
|
||||||
if [ "$MODULE_REAGENT_BANK" = "1" ] && [ ! -d "mod-reagent-bank" ]; then
|
if [ "$MODULE_REAGENT_BANK" = "1" ] && [ ! -d "mod-reagent-bank" ]; then
|
||||||
@@ -447,7 +437,6 @@ if [ "$MODULE_REAGENT_BANK" = "1" ] && [ ! -d "mod-reagent-bank" ]; then
|
|||||||
echo ' 📖 Project: https://github.com/ZhengPeiRu21/mod-reagent-bank'
|
echo ' 📖 Project: https://github.com/ZhengPeiRu21/mod-reagent-bank'
|
||||||
echo ' ℹ️ Reagent banker NPC for storing crafting materials, frees bag space'
|
echo ' ℹ️ Reagent banker NPC for storing crafting materials, frees bag space'
|
||||||
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
echo ' 🔧 REBUILD REQUIRED: Container must be rebuilt with source-based compilation'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/ZhengPeiRu21/mod-reagent-bank.git mod-reagent-bank
|
git clone https://github.com/ZhengPeiRu21/mod-reagent-bank.git mod-reagent-bank
|
||||||
fi
|
fi
|
||||||
if [ "$MODULE_BLACK_MARKET_AUCTION_HOUSE" = "1" ] && [ ! -d "mod-black-market" ]; then
|
if [ "$MODULE_BLACK_MARKET_AUCTION_HOUSE" = "1" ] && [ ! -d "mod-black-market" ]; then
|
||||||
@@ -456,7 +445,6 @@ if [ "$MODULE_BLACK_MARKET_AUCTION_HOUSE" = "1" ] && [ ! -d "mod-black-market" ]
|
|||||||
echo ' ℹ️ MoP Black Market Auction House backported using Eluna Lua engine'
|
echo ' ℹ️ MoP Black Market Auction House backported using Eluna Lua engine'
|
||||||
echo ' ⚠️ SPECIAL MODULE: Uses Lua scripts, not C++ compilation'
|
echo ' ⚠️ SPECIAL MODULE: Uses Lua scripts, not C++ compilation'
|
||||||
echo ' 🔧 REQUIRES: mod-eluna must be enabled and functional'
|
echo ' 🔧 REQUIRES: mod-eluna must be enabled and functional'
|
||||||
echo ' 🔬 STATUS: IN TESTING - Currently under verification'
|
|
||||||
git clone https://github.com/Youpeoples/Black-Market-Auction-House.git mod-black-market
|
git clone https://github.com/Youpeoples/Black-Market-Auction-House.git mod-black-market
|
||||||
|
|
||||||
# Special handling: Copy Lua scripts to lua_scripts directory
|
# Special handling: Copy Lua scripts to lua_scripts directory
|
||||||
@@ -768,7 +756,6 @@ ENABLED_MODULES=""
|
|||||||
[ "$MODULE_GAIN_HONOR_GUARD" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-gain-honor-guard"
|
[ "$MODULE_GAIN_HONOR_GUARD" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-gain-honor-guard"
|
||||||
[ "$MODULE_ELUNA" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-eluna"
|
[ "$MODULE_ELUNA" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-eluna"
|
||||||
[ "$MODULE_TIME_IS_TIME" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-time-is-time"
|
[ "$MODULE_TIME_IS_TIME" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-time-is-time"
|
||||||
[ "$MODULE_POCKET_PORTAL" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-pocket-portal"
|
|
||||||
[ "$MODULE_RANDOM_ENCHANTS" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-random-enchants"
|
[ "$MODULE_RANDOM_ENCHANTS" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-random-enchants"
|
||||||
[ "$MODULE_SOLOCRAFT" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-solocraft"
|
[ "$MODULE_SOLOCRAFT" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-solocraft"
|
||||||
[ "$MODULE_PVP_TITLES" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-pvp-titles"
|
[ "$MODULE_PVP_TITLES" = "1" ] && ENABLED_MODULES="$ENABLED_MODULES mod-pvp-titles"
|
||||||
|
|||||||
@@ -41,6 +41,16 @@ read_env(){
|
|||||||
echo "$value"
|
echo "$value"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
default_source_path(){
|
||||||
|
local module_playerbots
|
||||||
|
module_playerbots="$(read_env MODULE_PLAYERBOTS "0")"
|
||||||
|
if [ "$module_playerbots" = "1" ]; then
|
||||||
|
echo "./source/azerothcore-playerbots"
|
||||||
|
else
|
||||||
|
echo "./source/azerothcore"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
confirm(){
|
confirm(){
|
||||||
local prompt="$1" default="$2" reply
|
local prompt="$1" default="$2" reply
|
||||||
if [ "$ASSUME_YES" = "1" ]; then
|
if [ "$ASSUME_YES" = "1" ]; then
|
||||||
@@ -82,24 +92,39 @@ fi
|
|||||||
|
|
||||||
STORAGE_PATH="$(read_env STORAGE_PATH "./storage")"
|
STORAGE_PATH="$(read_env STORAGE_PATH "./storage")"
|
||||||
if [[ "$STORAGE_PATH" != /* ]]; then
|
if [[ "$STORAGE_PATH" != /* ]]; then
|
||||||
STORAGE_PATH="$PROJECT_DIR/$STORAGE_PATH"
|
STORAGE_PATH="$PROJECT_DIR/${STORAGE_PATH#./}"
|
||||||
fi
|
fi
|
||||||
MODULES_DIR="$STORAGE_PATH/modules"
|
MODULES_DIR="$STORAGE_PATH/modules"
|
||||||
SENTINEL_FILE="$MODULES_DIR/.requires_rebuild"
|
SENTINEL_FILE="$MODULES_DIR/.requires_rebuild"
|
||||||
|
|
||||||
|
STORAGE_PATH_ABS="$STORAGE_PATH"
|
||||||
|
|
||||||
REBUILD_SOURCE_PATH="$SOURCE_OVERRIDE"
|
REBUILD_SOURCE_PATH="$SOURCE_OVERRIDE"
|
||||||
|
default_path="$(default_source_path)"
|
||||||
if [ -z "$REBUILD_SOURCE_PATH" ]; then
|
if [ -z "$REBUILD_SOURCE_PATH" ]; then
|
||||||
REBUILD_SOURCE_PATH="$(read_env MODULES_REBUILD_SOURCE_PATH "./source/azerothcore")"
|
REBUILD_SOURCE_PATH="$(read_env MODULES_REBUILD_SOURCE_PATH "$default_path")"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$REBUILD_SOURCE_PATH" ]; then
|
if [ -z "$REBUILD_SOURCE_PATH" ]; then
|
||||||
REBUILD_SOURCE_PATH="./source/azerothcore"
|
REBUILD_SOURCE_PATH="$default_path"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "$REBUILD_SOURCE_PATH" != /* ]]; then
|
if [[ "$REBUILD_SOURCE_PATH" != /* ]]; then
|
||||||
REBUILD_SOURCE_PATH="$(realpath "$REBUILD_SOURCE_PATH" 2>/dev/null || echo "$REBUILD_SOURCE_PATH")"
|
REBUILD_SOURCE_PATH="$PROJECT_DIR/${REBUILD_SOURCE_PATH#./}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ "$default_path" != /* ]]; then
|
||||||
|
default_path_abs="$PROJECT_DIR/${default_path#./}"
|
||||||
|
else
|
||||||
|
default_path_abs="$default_path"
|
||||||
|
fi
|
||||||
|
if [[ "$REBUILD_SOURCE_PATH" == "$STORAGE_PATH_ABS"* ]]; then
|
||||||
|
echo "⚠️ Source path $REBUILD_SOURCE_PATH is inside shared storage ($STORAGE_PATH_ABS). Using local workspace $default_path_abs instead."
|
||||||
|
REBUILD_SOURCE_PATH="$default_path_abs"
|
||||||
|
fi
|
||||||
|
|
||||||
|
REBUILD_SOURCE_PATH="$(realpath "$REBUILD_SOURCE_PATH" 2>/dev/null || echo "$REBUILD_SOURCE_PATH")"
|
||||||
|
|
||||||
SOURCE_COMPOSE="$REBUILD_SOURCE_PATH/docker-compose.yml"
|
SOURCE_COMPOSE="$REBUILD_SOURCE_PATH/docker-compose.yml"
|
||||||
if [ ! -f "$SOURCE_COMPOSE" ]; then
|
if [ ! -f "$SOURCE_COMPOSE" ]; then
|
||||||
echo "❌ Source docker-compose.yml not found at $SOURCE_COMPOSE"
|
echo "❌ Source docker-compose.yml not found at $SOURCE_COMPOSE"
|
||||||
|
|||||||
@@ -9,24 +9,53 @@ if [ -f .env ]; then
|
|||||||
source .env
|
source .env
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Default values
|
# Remember project root for path normalization
|
||||||
SOURCE_PATH="${MODULES_REBUILD_SOURCE_PATH:-./source/azerothcore}"
|
PROJECT_ROOT="$(pwd)"
|
||||||
|
|
||||||
# Convert to absolute path if relative
|
# Default values
|
||||||
if [[ "$SOURCE_PATH" != /* ]]; then
|
|
||||||
SOURCE_PATH="$(pwd)/$SOURCE_PATH"
|
|
||||||
fi
|
|
||||||
MODULE_PLAYERBOTS="${MODULE_PLAYERBOTS:-0}"
|
MODULE_PLAYERBOTS="${MODULE_PLAYERBOTS:-0}"
|
||||||
|
DEFAULT_STANDARD_PATH="./source/azerothcore"
|
||||||
|
DEFAULT_PLAYERBOTS_PATH="./source/azerothcore-playerbots"
|
||||||
|
|
||||||
|
SOURCE_PATH_DEFAULT="$DEFAULT_STANDARD_PATH"
|
||||||
|
if [ "$MODULE_PLAYERBOTS" = "1" ]; then
|
||||||
|
SOURCE_PATH_DEFAULT="$DEFAULT_PLAYERBOTS_PATH"
|
||||||
|
fi
|
||||||
|
SOURCE_PATH="${MODULES_REBUILD_SOURCE_PATH:-$SOURCE_PATH_DEFAULT}"
|
||||||
|
|
||||||
|
STORAGE_PATH_VALUE="${STORAGE_PATH:-./storage}"
|
||||||
|
if [[ "$STORAGE_PATH_VALUE" != /* ]]; then
|
||||||
|
STORAGE_PATH_ABS="$PROJECT_ROOT/${STORAGE_PATH_VALUE#./}"
|
||||||
|
else
|
||||||
|
STORAGE_PATH_ABS="$STORAGE_PATH_VALUE"
|
||||||
|
fi
|
||||||
|
|
||||||
|
DEFAULT_SOURCE_ABS="$PROJECT_ROOT/${SOURCE_PATH_DEFAULT#./}"
|
||||||
|
|
||||||
|
# Convert to absolute path if relative and ensure we stay local
|
||||||
|
if [[ "$SOURCE_PATH" != /* ]]; then
|
||||||
|
SOURCE_PATH="$PROJECT_ROOT/${SOURCE_PATH#./}"
|
||||||
|
fi
|
||||||
|
if [[ "$SOURCE_PATH" == "$STORAGE_PATH_ABS"* ]]; then
|
||||||
|
echo "⚠️ Source path $SOURCE_PATH is inside shared storage ($STORAGE_PATH_ABS). Using local workspace $DEFAULT_SOURCE_ABS instead."
|
||||||
|
SOURCE_PATH="$DEFAULT_SOURCE_ABS"
|
||||||
|
MODULES_REBUILD_SOURCE_PATH="$SOURCE_PATH_DEFAULT"
|
||||||
|
fi
|
||||||
|
|
||||||
|
ACORE_REPO_STANDARD="${ACORE_REPO_STANDARD:-https://github.com/azerothcore/azerothcore-wotlk.git}"
|
||||||
|
ACORE_BRANCH_STANDARD="${ACORE_BRANCH_STANDARD:-master}"
|
||||||
|
ACORE_REPO_PLAYERBOTS="${ACORE_REPO_PLAYERBOTS:-https://github.com/uprightbass360/azerothcore-wotlk-playerbots.git}"
|
||||||
|
ACORE_BRANCH_PLAYERBOTS="${ACORE_BRANCH_PLAYERBOTS:-Playerbot}"
|
||||||
|
|
||||||
# Repository and branch selection based on playerbots mode
|
# Repository and branch selection based on playerbots mode
|
||||||
if [ "$MODULE_PLAYERBOTS" = "1" ]; then
|
if [ "$MODULE_PLAYERBOTS" = "1" ]; then
|
||||||
REPO_URL="https://github.com/liyunfan1223/azerothcore-wotlk.git"
|
REPO_URL="$ACORE_REPO_PLAYERBOTS"
|
||||||
BRANCH="Playerbot"
|
BRANCH="$ACORE_BRANCH_PLAYERBOTS"
|
||||||
echo "📌 Playerbots mode: Using liyunfan1223 fork, Playerbot branch"
|
echo "📌 Playerbots mode: Using $REPO_URL, branch $BRANCH"
|
||||||
else
|
else
|
||||||
REPO_URL="https://github.com/azerothcore/azerothcore-wotlk.git"
|
REPO_URL="$ACORE_REPO_STANDARD"
|
||||||
BRANCH="master"
|
BRANCH="$ACORE_BRANCH_STANDARD"
|
||||||
echo "📌 Standard mode: Using official AzerothCore, master branch"
|
echo "📌 Standard mode: Using $REPO_URL, branch $BRANCH"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "📍 Repository: $REPO_URL"
|
echo "📍 Repository: $REPO_URL"
|
||||||
|
|||||||
29
setup.sh
29
setup.sh
@@ -904,14 +904,39 @@ fi
|
|||||||
fi
|
fi
|
||||||
if [ "$RUN_REBUILD_NOW" = "1" ] || [ "$AUTO_REBUILD_ON_DEPLOY" = "1" ]; then
|
if [ "$RUN_REBUILD_NOW" = "1" ] || [ "$AUTO_REBUILD_ON_DEPLOY" = "1" ]; then
|
||||||
if [ -z "$MODULES_REBUILD_SOURCE_PATH_VALUE" ]; then
|
if [ -z "$MODULES_REBUILD_SOURCE_PATH_VALUE" ]; then
|
||||||
|
if [ "$MODULE_PLAYERBOTS" = "1" ]; then
|
||||||
|
MODULES_REBUILD_SOURCE_PATH_VALUE="./source/azerothcore-playerbots"
|
||||||
|
else
|
||||||
MODULES_REBUILD_SOURCE_PATH_VALUE="./source/azerothcore"
|
MODULES_REBUILD_SOURCE_PATH_VALUE="./source/azerothcore"
|
||||||
|
fi
|
||||||
say INFO "Using default source path: ${MODULES_REBUILD_SOURCE_PATH_VALUE}"
|
say INFO "Using default source path: ${MODULES_REBUILD_SOURCE_PATH_VALUE}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
local default_source_rel="./source/azerothcore"
|
||||||
|
if [ "$MODULE_PLAYERBOTS" = "1" ]; then
|
||||||
|
default_source_rel="./source/azerothcore-playerbots"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -n "$MODULES_REBUILD_SOURCE_PATH_VALUE" ]; then
|
||||||
|
local storage_abs="$STORAGE_PATH"
|
||||||
|
if [[ "$storage_abs" != /* ]]; then
|
||||||
|
storage_abs="$(pwd)/${storage_abs#./}"
|
||||||
|
fi
|
||||||
|
local candidate_path="$MODULES_REBUILD_SOURCE_PATH_VALUE"
|
||||||
|
if [[ "$candidate_path" != /* ]]; then
|
||||||
|
candidate_path="$(pwd)/${candidate_path#./}"
|
||||||
|
fi
|
||||||
|
if [[ "$candidate_path" == "$storage_abs"* ]]; then
|
||||||
|
say WARNING "MODULES_REBUILD_SOURCE_PATH is inside shared storage (${candidate_path}). Using local workspace ${default_source_rel} instead."
|
||||||
|
MODULES_REBUILD_SOURCE_PATH_VALUE="$default_source_rel"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$RUN_REBUILD_NOW" = "1" ]; then
|
if [ "$RUN_REBUILD_NOW" = "1" ]; then
|
||||||
local rebuild_source_path="${MODULES_REBUILD_SOURCE_PATH_VALUE:-./source/azerothcore}"
|
local default_source_path="$default_source_rel"
|
||||||
|
local rebuild_source_path="${MODULES_REBUILD_SOURCE_PATH_VALUE:-$default_source_path}"
|
||||||
if [ ! -f "$rebuild_source_path/docker-compose.yml" ]; then
|
if [ ! -f "$rebuild_source_path/docker-compose.yml" ]; then
|
||||||
say INFO "Preparing source repository via scripts/setup-source.sh"
|
say INFO "Preparing source repository via scripts/setup-source.sh"
|
||||||
if ! ./scripts/setup-source.sh >/dev/null 2>&1; then
|
if ! ./scripts/setup-source.sh >/dev/null 2>&1; then
|
||||||
@@ -945,7 +970,7 @@ fi
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$MODULES_REBUILD_SOURCE_PATH_VALUE" ]; then
|
if [ -z "$MODULES_REBUILD_SOURCE_PATH_VALUE" ]; then
|
||||||
MODULES_REBUILD_SOURCE_PATH_VALUE="./source/azerothcore"
|
MODULES_REBUILD_SOURCE_PATH_VALUE="$default_source_rel"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
DB_PLAYERBOTS_NAME=${DB_PLAYERBOTS_NAME:-acore_playerbots}
|
DB_PLAYERBOTS_NAME=${DB_PLAYERBOTS_NAME:-acore_playerbots}
|
||||||
|
|||||||
Reference in New Issue
Block a user