fix(migration): atomic /usr/bin/update replacement to prevent syntax errors (#12540)

This commit is contained in:
CanbiZ (MickLesk)
2026-03-04 07:59:51 +01:00
committed by GitHub
parent 2521412747
commit cf8043a22e
8 changed files with 25 additions and 11 deletions

View File

@@ -45,14 +45,15 @@ function update_script() {
fi
msg_info "Switching update script to Seerr"
cat <<'EOF' >/usr/bin/update
#!/usr/bin/env bash
TMP_UPDATE=$(mktemp)
cat <<'EOF' >"$TMP_UPDATE"
bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/seerr.sh)"
EOF
mv "$TMP_UPDATE" /usr/bin/update
chmod +x /usr/bin/update
msg_ok "Switched update script to Seerr"
msg_warn "Please type 'update' again to complete the migration"
exit
exit 0
fi
msg_info "Updating Jellyseerr"