Fix error when attempting to remove missing webhook 00/122300/2
authorTodd Malsbary <todd.malsbary@intel.com>
Mon, 28 Jun 2021 19:54:46 +0000 (12:54 -0700)
committerTodd Malsbary <todd.malsbary@intel.com>
Wed, 30 Jun 2021 20:33:42 +0000 (20:33 +0000)
Issue-ID: MULTICLOUD-1370
Signed-off-by: Todd Malsbary <todd.malsbary@intel.com>
Change-Id: If3b71f64b5994bbe6bd68e2b620452f4081cd705

kud/hosting_providers/vagrant/installer.sh

index 5535c31..7547291 100755 (executable)
@@ -178,7 +178,7 @@ function install_addons {
             popd
         done
         # Remove Kata webhook if user didn't want it permanently installed
-        if ! [ "${enable_kata_webhook}" == "true" ]; then
+        if ! [ "${enable_kata_webhook}" == "true" ] && [ "${kata_webhook_deployed}" == "true" ]; then
             ansible-playbook $verbose -i $kud_inventory -e "base_dest=$HOME" \
                 -e "kata_webhook_runtimeclass=$kata_webhook_runtimeclass" \
                 $kud_playbooks/configure-kata-webhook-reset.yml \