From 1948dce69b83b10345c250865a39a335e9499d7f Mon Sep 17 00:00:00 2001 From: Rakshith R Date: Mon, 9 Aug 2021 11:53:40 +0530 Subject: [PATCH] ci: internally create & delete cephcsi namespace in install-helm.sh This ensures the kubectl call is retried with kubectl_retry function. Updates: #2309 Signed-off-by: Rakshith R (cherry picked from commit 7fba62dd47d7573d2840c7df8ee38d13b7d7e21c) --- scripts/install-helm.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/install-helm.sh b/scripts/install-helm.sh index dc9636c11..3e422fb0f 100755 --- a/scripts/install-helm.sh +++ b/scripts/install-helm.sh @@ -133,6 +133,8 @@ install_cephcsi_helm_charts() { NAMESPACE="default" fi + kubectl_retry create namespace ${NAMESPACE} + # label the nodes uniformly for domain information for node in $(kubectl_retry get node -o jsonpath='{.items[*].metadata.name}'); do kubectl_retry label node/"${node}" ${NODE_LABEL_REGION}=${REGION_VALUE} @@ -167,6 +169,7 @@ cleanup_cephcsi_helm_charts() { fi "${HELM}" uninstall ${CEPHFS_CHART_NAME} --namespace ${NAMESPACE} "${HELM}" uninstall ${RBD_CHART_NAME} --namespace ${NAMESPACE} + kubectl_retry delete namespace ${NAMESPACE} } helm_reset() {