From 95412140734c6254777fc81d137157b649947129 Mon Sep 17 00:00:00 2001 From: Jason Ertel Date: Fri, 20 Jan 2023 12:26:52 -0500 Subject: [PATCH] logCmd with tee is eating the exit code --- setup/so-functions | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/setup/so-functions b/setup/so-functions index 03221d0e9..a046b49ca 100755 --- a/setup/so-functions +++ b/setup/so-functions @@ -2382,7 +2382,11 @@ wait_for_salt_minion() { } verify_setup() { - if logCmd ./so-verify "$setup_type"; then + info "Verifying setup" + output=$(./so-verify "$setup_type" 2>&1) + result=$? + echo "$output" >> "$setup_log" + if [[ $result -eq 0 ]]; then whiptail_setup_complete else whiptail_setup_failed