Add namespace name to release name 55/355/1
authorwrider <lji@research.att.com>
Mon, 17 Jun 2019 19:16:21 +0000 (15:16 -0400)
committerwrider <lji@research.att.com>
Mon, 17 Jun 2019 19:16:27 +0000 (15:16 -0400)
Credentials are per namespace therefore we need to deploy this chart
for each namespace where the credential is needed.  The helm release
name used for deploying the chart to each namespace should reflect the
namespace; otherwise we will have "release already exists" error when
deploy the credential into the second namespace in the same cluster.

Change-Id: I8fb013900113f3f16ecff40b8c32edfd32679a06
Signed-off-by: wrider <lji@research.att.com>
ric-infra/20-Credential/bin/install
ric-infra/20-Credential/bin/uninstall

index a261990..eb7bf21 100755 (executable)
@@ -45,8 +45,8 @@ cp /tmp/common-$COMMON_CHART_VERSION.tgz $DIR/../helm/charts/
 
 
 if [ -z $OVERRIDEYAML ]; then
-  helm install --namespace "${NAMESPACE}" --name "${RELEASE_NAME}-credential" $DIR/../helm
+  helm install --namespace "${NAMESPACE}" --name "${RELEASE_NAME}-${NAMESPACE}-credential" $DIR/../helm
 else
-  helm install -f $OVERRIDEYAML --namespace "${NAMESPACE}" --name "${RELEASE_NAME}-credential" $DIR/../helm
+  helm install -f $OVERRIDEYAML --namespace "${NAMESPACE}" --name "${RELEASE_NAME}-${NAMESPACE}-credential" $DIR/../helm
 fi
 
index f93004a..c820c7f 100755 (executable)
@@ -36,5 +36,5 @@ else
    NAMESPACE=$RICPLT_NAMESPACE
 fi
 
-  helm delete --purge "${RELEASE_NAME}-credential"
+helm delete --purge "${RELEASE_NAME}-${NAMESPACE}-credential"