mirror of
https://github.com/itzg/docker-minecraft-server.git
synced 2026-03-02 12:56:25 +00:00
Quieter Paper/Bukkit default configs downloading (#3535)
This commit is contained in:
@@ -14,7 +14,9 @@ handleDebugMode
|
||||
: "${REPLACE_ENV_VARIABLES_EXCLUDE_PATHS:=}"
|
||||
: "${PATCH_DEFINITIONS:=}"
|
||||
: "${DEBUG:=false}"
|
||||
: "${DOWNLOAD_DEFAULTS:=}"
|
||||
: "${DOWNLOAD_DEFAULT_CONFIGS:=}"
|
||||
: "${SKIP_DOWNLOAD_DEFAULTS:=false}"
|
||||
|
||||
if isTrue "${REPLACE_ENV_IN_PLACE}"; then
|
||||
log "Replacing env variables in ${REPLACE_ENV_PATHS} that match the prefix '$REPLACE_ENV_VARIABLE_PREFIX' ..."
|
||||
@@ -27,22 +29,28 @@ if isTrue "${REPLACE_ENV_IN_PLACE}"; then
|
||||
"${REPLACE_ENV_PATHS[@]}"
|
||||
fi
|
||||
|
||||
if [[ $DOWNLOAD_DEFAULT_CONFIGS ]]; then
|
||||
log "Downloading default configs, if needed"
|
||||
if ! mc-image-helper mcopy \
|
||||
--to /data/config \
|
||||
--skip-existing --skip-up-to-date=false \
|
||||
"$DOWNLOAD_DEFAULT_CONFIGS" 2> /dev/null; then
|
||||
logWarning "One or more default config files were not available from $DOWNLOAD_DEFAULT_CONFIGS"
|
||||
if isFalse "$SKIP_DOWNLOAD_DEFAULTS"; then
|
||||
commonArgs=(
|
||||
--skip-existing
|
||||
--skip-up-to-date=false
|
||||
--quiet-when-skipped
|
||||
--ignore-missing-sources
|
||||
)
|
||||
if [[ $DOWNLOAD_DEFAULT_CONFIGS ]]; then
|
||||
if ! mc-image-helper mcopy \
|
||||
--to /data/config \
|
||||
"${commonArgs[@]}" \
|
||||
"$DOWNLOAD_DEFAULT_CONFIGS"; then
|
||||
logWarning "One or more default config files were not available from $DOWNLOAD_DEFAULT_CONFIGS"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
if [[ $DOWNLOAD_DEFAULTS ]]; then
|
||||
log "Downloading default top-level configs, if needed"
|
||||
if ! mc-image-helper mcopy \
|
||||
--to /data \
|
||||
--skip-existing --skip-up-to-date=false \
|
||||
"$DOWNLOAD_DEFAULTS" 2> /dev/null; then
|
||||
logWarning "One or more default files were not available from $DOWNLOAD_DEFAULTS"
|
||||
if [[ $DOWNLOAD_DEFAULTS ]]; then
|
||||
if ! mc-image-helper mcopy \
|
||||
--to /data \
|
||||
"${commonArgs[@]}" \
|
||||
"$DOWNLOAD_DEFAULTS"; then
|
||||
logWarning "One or more default files were not available from $DOWNLOAD_DEFAULTS"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user