From 286d7aad449ede8941353c7372713b828bd41d28 Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Wed, 30 Aug 2023 17:24:55 +0000 Subject: [PATCH] Fix incorrect error handling --- bootstrap-daemon/pvcbootstrapd/lib/tftp.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bootstrap-daemon/pvcbootstrapd/lib/tftp.py b/bootstrap-daemon/pvcbootstrapd/lib/tftp.py index bf9f2be..d8fdaae 100755 --- a/bootstrap-daemon/pvcbootstrapd/lib/tftp.py +++ b/bootstrap-daemon/pvcbootstrapd/lib/tftp.py @@ -31,8 +31,8 @@ def build_tftp_repository(config): build_cmd = [ f"{config['ansible_path']}/pvc-installer/buildpxe.sh", "-o", config['tftp_root_path'], "-u", config['deploy_username'], "-m", config["repo_mirror"] ] print(f"Building TFTP contents via pvc-installer command: {' '.join(build_cmd)}") notifications.send_webhook(config, "begin", f"Building TFTP contents via pvc-installer command: {' '.join(build_cmd)}") - retcode = run(build_cmd) - return True if retcode == 0 else False + ret = run(build_cmd) + return True if ret.returncode == 0 else False def init_tftp(config):