mirror of
https://github.com/itzg/docker-minecraft-server.git
synced 2026-09-18 11:57:57 +00:00
Add REMOVE_OLD_CONFIGS to clear old configs before modpack install (#4266)
This commit is contained in:
@@ -9,6 +9,11 @@ set -e -o pipefail
|
||||
: "${PLUGINS_FILE:=}"
|
||||
: "${REMOVE_OLD_MODS_DEPTH:=1} "
|
||||
: "${REMOVE_OLD_MODS_INCLUDE:=*.jar,*-version.json}"
|
||||
: "${REMOVE_OLD_CONFIGS:=false}"
|
||||
: "${CONFIG_OUT_DIR:=/data/config}"
|
||||
: "${REMOVE_OLD_CONFIGS_DEPTH:=16}"
|
||||
: "${REMOVE_OLD_CONFIGS_INCLUDE:=*}"
|
||||
: "${REMOVE_OLD_CONFIGS_EXCLUDE:=}"
|
||||
: "${CF_USE_HTTP2:=false}" # CF downloads are faster with HTTP 1.1
|
||||
: "${MODRINTH_LOADER:=}"
|
||||
|
||||
@@ -25,6 +30,10 @@ if isTrue "${REMOVE_OLD_MODS}" && [ -z "${MODS_FILE}" ]; then
|
||||
rm -f "$sum_file"
|
||||
fi
|
||||
|
||||
if isTrue "${REMOVE_OLD_CONFIGS}"; then
|
||||
removeOldConfigs "$CONFIG_OUT_DIR"
|
||||
fi
|
||||
|
||||
function handlePackwiz() {
|
||||
# If packwiz url passed, bootstrap packwiz and update mods before other modpack processing
|
||||
if [[ "${PACKWIZ_URL:-}" ]]; then
|
||||
|
||||
Reference in New Issue
Block a user