fix(installer): remove duplicate config load that kills upgrade silently
All checks were successful
CI / build (push) Successful in 1m18s
CI / docker (push) Successful in 15s

The upgrade path in handle_rerun called load_config_file a second time
(already called by detect_existing_install). On the second pass, every
variable is already set, so [ -z "$VAR" ] && VAR="$value" returns
exit code 1 (test fails, && short-circuits). With set -e, the non-zero
exit from the case clause kills the script silently after printing
"[INFO] Upgrading installation..." — no error, no further output.

Removed the redundant load_config_file and load_env_overrides calls.
Both were already executed in main() before handle_rerun is reached.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-04-25 09:03:07 +02:00
parent 9f3faf4816
commit 6fe10432e6

View File

@@ -1406,8 +1406,9 @@ handle_rerun() {
case "$RERUN_ACTION" in
upgrade)
log_info "Upgrading installation..."
load_config_file "$INSTALL_DIR/cameleer.conf"
load_env_overrides
# Config already loaded by detect_existing_install + load_env_overrides in main.
# Calling load_config_file again with set -e causes silent exit because
# [ -z "$VAR" ] && VAR="$value" returns 1 for every already-set variable.
merge_config
copy_templates
docker_registry_login