[COMMON] Fix bad subchartDot retrieving 96/108196/4
authorSylvain Desbureaux <sylvain.desbureaux@orange.com>
Mon, 25 May 2020 11:05:45 +0000 (13:05 +0200)
committerKrzysztof Opasiak <k.opasiak@samsung.com>
Thu, 11 Jun 2020 12:39:44 +0000 (12:39 +0000)
readinessCheck was retrieving "subchartDot" in string format and not in
"object" format.
This commit fixes it

Issue-ID: OOM-1971
Signed-off-by: Sylvain Desbureaux <sylvain.desbureaux@orange.com>
Change-Id: I04060f973d283802e6269dc67370a336c5bcf95e

kubernetes/common/readinessCheck/templates/_readinessCheck.tpl

index 5c70e78..1bdea6b 100644 (file)
@@ -40,8 +40,8 @@
 {{-   $dot := default . .dot -}}
 {{-   $initRoot := default $dot.Values.readinessCheck .initRoot -}}
 {{/*  Our version of helm doesn't support deepCopy so we need this nasty trick */}}
-{{-   $subchartDot := include "common.subChartDot" (dict "dot" $dot "initRoot" $initRoot) }}
-{{-   $wait_for := default $dot.Values.wait_for .wait_for -}}
+{{-   $subchartDot := fromJson (include "common.subChartDot" (dict "dot" $dot "initRoot" $initRoot)) }}
+{{-   $wait_for := default $initRoot.wait_for .wait_for -}}
 - name: {{ include "common.name" $dot }}-{{ $wait_for.name }}-readiness
   image: "{{ $subchartDot.Values.global.readinessRepository }}/{{ $subchartDot.Values.global.readinessImage }}"
   imagePullPolicy: {{ $subchartDot.Values.global.pullPolicy | default $subchartDot.Values.pullPolicy }}