X-Git-Url: https://gerrit.akraino.org/r/gitweb?a=blobdiff_plain;f=deploy%2Fbaremetal-operator%2Fbaremetal-operator.sh;h=34c5977d8acf7cc13ce80e0c4ac1737128103145;hb=refs%2Fchanges%2F04%2F4704%2F1;hp=35e79a19fd92c84aedbb58c91b60de02cc0585a5;hpb=718425df1f99dd7f93cb60bbe9eb01cab9e47f2a;p=icn.git diff --git a/deploy/baremetal-operator/baremetal-operator.sh b/deploy/baremetal-operator/baremetal-operator.sh index 35e79a1..34c5977 100755 --- a/deploy/baremetal-operator/baremetal-operator.sh +++ b/deploy/baremetal-operator/baremetal-operator.sh @@ -9,7 +9,9 @@ source $LIBDIR/common.sh trap err_exit ERR function err_exit { - kubectl get all -n baremetal-operator-system + if command -v kubectl; then + kubectl get all -n baremetal-operator-system + fi } # This may be used to update the in-place Bare Metal Operator YAML @@ -30,7 +32,7 @@ function deploy { } function clean { - kustomize build ${SCRIPTDIR}/icn | kubectl delete -f - + kustomize build ${SCRIPTDIR}/icn | kubectl delete --ignore-not-found=true -f - } case $1 in