From 2d5a8cf967b86709fbe878433e3efb879df5a9a5 Mon Sep 17 00:00:00 2001 From: ankit <ankit.dhn31@gmail.com> Date: Mon, 9 Dec 2019 07:44:21 +0000 Subject: [PATCH] Fixes issue with checking whether ISO is passed This patch fixes the issue if IRONIC_BUILD_DEPLOY_RAMDISK is set to false and IRONIC_DEPLOY_ISO is passed then it will not throw the error. Change-Id: Ic95f6e75d51db5cb60098bb131698cf44e772366 Story: 2007002 Task: 37777 --- devstack/lib/ironic | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devstack/lib/ironic b/devstack/lib/ironic index a9e516fe7e..caa1966179 100644 --- a/devstack/lib/ironic +++ b/devstack/lib/ironic @@ -293,7 +293,7 @@ IRONIC_DIB_DHCP_TIMEOUT=${IRONIC_DIB_DHCP_TIMEOUT:-60} IRONIC_DEPLOY_ISO_REQUIRED=$(trueorfalse False IRONIC_DEPLOY_ISO_REQUIRED) if [[ "$IRONIC_DEPLOY_ISO_REQUIRED" = "True" \ && "$IRONIC_BUILD_DEPLOY_RAMDISK" = "False" \ - && -n "$IRONIC_DEPLOY_ISO" ]]; then + && ! -e "$IRONIC_DEPLOY_ISO" ]]; then die "Prebuilt ISOs are not available, provide an ISO via IRONIC_DEPLOY_ISO \ or set IRONIC_BUILD_DEPLOY_RAMDISK=True to use ISOs" fi