From 2b91caa24b90c89873ced45c3c808756b4e2bb8b Mon Sep 17 00:00:00 2001 From: shocknet-justin Date: Sun, 31 Aug 2025 13:30:59 -0400 Subject: [PATCH] debug exit --- scripts/install.sh | 7 +++---- scripts/start_services.sh | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/scripts/install.sh b/scripts/install.sh index 712b51bc..8da406fa 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -119,10 +119,9 @@ else # Run install_lightning_pub and capture its exit code directly. # Exit codes from install_lightning_pub: 0=fresh, 100=upgrade, 2=no-op - install_lightning_pub "$REPO_URL" - pub_install_status=$? + install_lightning_pub "$REPO_URL" || pub_install_status=$? - case $pub_install_status in + case ${pub_install_status:-0} in 0) log "Lightning.Pub fresh installation completed successfully." pub_upgrade_status=0 # Indicates a fresh install, services should start @@ -136,7 +135,7 @@ else pub_upgrade_status=2 # Special status to skip service restart ;; *) - log_error "Lightning.Pub installation failed with exit code $pub_install_status" $pub_install_status + log_error "Lightning.Pub installation failed with exit code $pub_install_status" "$pub_install_status" ;; esac diff --git a/scripts/start_services.sh b/scripts/start_services.sh index 4b821707..bce4a7c1 100755 --- a/scripts/start_services.sh +++ b/scripts/start_services.sh @@ -57,7 +57,7 @@ start_services() { if [ "$PUB_UPGRADE" = "0" ] || [ "$PUB_UPGRADE" = "100" ]; then if [ "$PUB_UPGRADE" = "100" ]; then - log "${PRIMARY_COLOR}Starting${RESET_COLOR} ${SECONDARY_COLOR}Lightning.Pub${RESET_COLOR} service after upgrade..." +t log "${PRIMARY_COLOR}Restarting${RESET_COLOR} ${SECONDARY_COLOR}Lightning.Pub${RESET_COLOR} service after upgrade..." else log "${PRIMARY_COLOR}Starting${RESET_COLOR} ${SECONDARY_COLOR}Lightning.Pub${RESET_COLOR} service..." fi