summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBartek Grzybowski <b.grzybowski@partner.samsung.com>2021-06-24 13:35:31 +0200
committerBartek Grzybowski <b.grzybowski@partner.samsung.com>2021-07-01 11:49:56 +0000
commit0e2f968d4997c0e5afe35d81087bc7d1b239de69 (patch)
tree6200359ac451c1b2d7b198c821faf707c9863531
parent76cd106951044a14b6c01db795f2681be55e7b58 (diff)
[TOOLS] Drop Helm v2 specific code
Change-Id: I7ca2889bf3a7296b4c88786cd6f304a86ca007a5 Issue-ID: OOM-2770 Signed-off-by: Bartek Grzybowski <b.grzybowski@partner.samsung.com>
-rwxr-xr-xtools/helm-healer.sh22
1 files changed, 3 insertions, 19 deletions
diff --git a/tools/helm-healer.sh b/tools/helm-healer.sh
index 9395e079..7dd9c2eb 100755
--- a/tools/helm-healer.sh
+++ b/tools/helm-healer.sh
@@ -12,7 +12,7 @@ HELM_CHART_RELEASE_NAME=
HELM_DELETE_ALL=
HELM_SKIP_DEPLOY=
VOLUME_STORAGE=
-HELM_TIMEOUT=3600
+HELM_TIMEOUT=3600s
RELEASE_PREFIX=onap
#
@@ -190,25 +190,14 @@ get_labels()
helm_undeploy()
{
msg "Undeploy helm release name: ${1}"
- # Helm v3 does not support "--purge" flag since it's a default behavior for v3
- if [[ $(helm version --template "{{.Version}}") =~ ^v3 ]];then
- helm undeploy ${1}
- else
- helm undeploy ${1} --purge
- fi
+ helm undeploy ${1}
sleep 15s
}
helm_deploy()
{
- # Helm v3 need "--create-namespace" to create namespace if don't exist
- if [[ $(helm version --template "{{.Version}}") =~ ^v3 ]];then
msg helm deploy ${RELEASE_PREFIX} local/onap --create-namespace --namespace ${NAMESPACE} ${OVERRIDES} --timeout ${HELM_TIMEOUT}
helm deploy ${RELEASE_PREFIX} local/onap --create-namespace --namespace ${NAMESPACE} ${OVERRIDES} --timeout ${HELM_TIMEOUT}
- else
- msg helm deploy ${RELEASE_PREFIX} local/onap --namespace ${NAMESPACE} ${OVERRIDES} --timeout ${HELM_TIMEOUT}
- helm deploy ${RELEASE_PREFIX} local/onap --namespace ${NAMESPACE} ${OVERRIDES} --timeout ${HELM_TIMEOUT}
- fi
}
# arg: <job name>
@@ -612,7 +601,7 @@ if [ -n "$arg_prefix" ] ; then
fi
if [ -n "$arg_timeout" ] ; then
- HELM_TIMEOUT="$arg_timeout"
+ HELM_TIMEOUT="${arg_timeout}s"
fi
if [ -n "$arg_storage" ] ; then
@@ -635,11 +624,6 @@ if [ -n "$arg_cleanonly" ] ; then
HELM_SKIP_DEPLOY=yes
fi
-# If running with helm v3 a time unit has to be appended to HELM_TIMEOUT
-if [[ $(helm version --template "{{.Version}}") =~ ^v3 ]];then
- HELM_TIMEOUT="${HELM_TIMEOUT}s"
-fi
-
#
# main
#