From bbb97dbfda33d9727d583be7932fe37549d1a6a4 Mon Sep 17 00:00:00 2001 From: Muhammad Ibrahim Date: Thu, 2 Oct 2025 14:37:38 +0100 Subject: [PATCH] fix: Remove EXIT from error trap to prevent false failures on successful completion --- agents/proxmox_auto_enroll.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/agents/proxmox_auto_enroll.sh b/agents/proxmox_auto_enroll.sh index 4ff08d7..0c44b18 100755 --- a/agents/proxmox_auto_enroll.sh +++ b/agents/proxmox_auto_enroll.sh @@ -1,10 +1,10 @@ #!/bin/bash set -euo pipefail # Exit on error, undefined vars, pipe failures -# Trap to catch any unexpected exits -trap 'echo "[ERROR] Script exited unexpectedly at line $LINENO with exit code $?"' ERR EXIT +# Trap to catch errors only (not normal exits) +trap 'echo "[ERROR] Script failed at line $LINENO with exit code $?"' ERR -SCRIPT_VERSION="1.0.0-debug.10" +SCRIPT_VERSION="1.0.1" echo "[DEBUG] Script Version: $SCRIPT_VERSION ($(date +%Y-%m-%d\ %H:%M:%S))" # =============================================================================