From 11f02edc43984667684930901fc2e3571046223f Mon Sep 17 00:00:00 2001 From: Andrii Ostapenko Date: Tue, 17 Sep 2019 09:56:07 -0500 Subject: [PATCH] Simplify code for value overrides for ceph Change-Id: I50cbd0b11b55711dc484c0a4c382301a4680edb3 --- tools/deployment/component/ceph/ceph.sh | 8 +------- tools/deployment/developer/ceph/040-ceph.sh | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/tools/deployment/component/ceph/ceph.sh b/tools/deployment/component/ceph/ceph.sh index 3a9ea9d0f3..9126bcc296 100755 --- a/tools/deployment/component/ceph/ceph.sh +++ b/tools/deployment/component/ceph/ceph.sh @@ -171,18 +171,12 @@ pod: EOF for CHART in ceph-mon ceph-osd ceph-client ceph-provisioners; do - #NOTE: Get the over-rides to use - if [ -z "${OSH_EXTRA_HELM_ARGS_CEPH}" ]; then - OSH_EXTRA_HELM_ARGS_CEPH_TMP="$(./tools/deployment/common/get-values-overrides.sh ${CHART})" - else - OSH_EXTRA_HELM_ARGS_CEPH_TMP="${OSH_EXTRA_HELM_ARGS_CEPH}" - fi helm upgrade --install ${CHART} ${HELM_CHART_ROOT_PATH}/${CHART} \ --namespace=ceph \ --values=/tmp/ceph.yaml \ ${OSH_EXTRA_HELM_ARGS:=} \ - ${OSH_EXTRA_HELM_ARGS_CEPH_TMP} + ${OSH_EXTRA_HELM_ARGS_CEPH:-$(./tools/deployment/common/get-values-overrides.sh ${CHART})} #NOTE: Wait for deploy ./tools/deployment/common/wait-for-pods.sh ceph diff --git a/tools/deployment/developer/ceph/040-ceph.sh b/tools/deployment/developer/ceph/040-ceph.sh index 015559ca38..0004c11b40 100755 --- a/tools/deployment/developer/ceph/040-ceph.sh +++ b/tools/deployment/developer/ceph/040-ceph.sh @@ -161,18 +161,12 @@ pod: EOF for CHART in ceph-mon ceph-osd ceph-client ceph-provisioners; do - #NOTE: Get the over-rides to use - if [ -z "${OSH_EXTRA_HELM_ARGS_CEPH}" ]; then - OSH_EXTRA_HELM_ARGS_CEPH_TMP="$(./tools/deployment/common/get-values-overrides.sh ${CHART})" - else - OSH_EXTRA_HELM_ARGS_CEPH_TMP="${OSH_EXTRA_HELM_ARGS_CEPH}" - fi helm upgrade --install ${CHART} ${HELM_CHART_ROOT_PATH}/${CHART} \ --namespace=ceph \ --values=/tmp/ceph.yaml \ ${OSH_EXTRA_HELM_ARGS} \ - ${OSH_EXTRA_HELM_ARGS_CEPH_TMP} + ${OSH_EXTRA_HELM_ARGS_CEPH:-$(./tools/deployment/common/get-values-overrides.sh ${CHART})} #NOTE: Wait for deploy ./tools/deployment/common/wait-for-pods.sh ceph