From b3829fef30e76fdf498fa1d0d35185f642dce5f6 Mon Sep 17 00:00:00 2001 From: Robert Church Date: Mon, 8 Apr 2019 02:12:39 -0400 Subject: [PATCH 4/4] Partial revert of 31e3469d28858d7b5eb6355e88b6f49fd62032be Suspect that new use of mergeOverwrite vs. merge is breaking the per-host DaemonSet overrides. Signed-off-by: Robert Church --- helm-toolkit/templates/utils/_daemonset_overrides.tpl | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/helm-toolkit/templates/utils/_daemonset_overrides.tpl b/helm-toolkit/templates/utils/_daemonset_overrides.tpl index 10ab166..ab1177a 100644 --- a/helm-toolkit/templates/utils/_daemonset_overrides.tpl +++ b/helm-toolkit/templates/utils/_daemonset_overrides.tpl @@ -49,10 +49,10 @@ limitations under the License. {{- $override_conf_copy := $host_data.conf }} {{/* Deep copy to prevent https://storyboard.openstack.org/#!/story/2005936 */}} {{- $root_conf_copy := omit ($context.Values.conf | toYaml | fromYaml) "overrides" }} - {{- $merged_dict := mergeOverwrite $root_conf_copy $override_conf_copy }} + {{- $merged_dict := merge $override_conf_copy $root_conf_copy }} {{- $root_conf_copy2 := dict "conf" $merged_dict }} {{- $context_values := omit (omit ($context.Values | toYaml | fromYaml) "conf") "__daemonset_list" }} - {{- $root_conf_copy3 := mergeOverwrite $context_values $root_conf_copy2 }} + {{- $root_conf_copy3 := merge $context_values $root_conf_copy2 }} {{- $root_conf_copy4 := dict "Values" $root_conf_copy3 }} {{- $_ := set $current_dict "nodeData" $root_conf_copy4 }} @@ -89,10 +89,10 @@ limitations under the License. {{- $override_conf_copy := $label_data.conf }} {{/* Deep copy to prevent https://storyboard.openstack.org/#!/story/2005936 */}} {{- $root_conf_copy := omit ($context.Values.conf | toYaml | fromYaml) "overrides" }} - {{- $merged_dict := mergeOverwrite $root_conf_copy $override_conf_copy }} + {{- $merged_dict := merge $override_conf_copy $root_conf_copy }} {{- $root_conf_copy2 := dict "conf" $merged_dict }} {{- $context_values := omit (omit ($context.Values | toYaml | fromYaml) "conf") "__daemonset_list" }} - {{- $root_conf_copy3 := mergeOverwrite $context_values $root_conf_copy2 }} + {{- $root_conf_copy3 := merge $context_values $root_conf_copy2 }} {{- $root_conf_copy4 := dict "Values" $root_conf_copy3 }} {{- $_ := set $context.Values.__current_label "nodeData" $root_conf_copy4 }} @@ -187,7 +187,7 @@ limitations under the License. {{- $root_conf_copy1 := omit $context.Values.conf "overrides" }} {{- $root_conf_copy2 := dict "conf" $root_conf_copy1 }} {{- $context_values := omit $context.Values "conf" }} - {{- $root_conf_copy3 := mergeOverwrite $context_values $root_conf_copy2 }} + {{- $root_conf_copy3 := merge $context_values $root_conf_copy2 }} {{- $root_conf_copy4 := dict "Values" $root_conf_copy3 }} {{- $_ := set $context.Values.__default "nodeData" $root_conf_copy4 }} @@ -198,7 +198,7 @@ limitations under the License. {{- range $current_dict := $context.Values.__daemonset_list }} {{- $context_novalues := omit $context "Values" }} - {{- $merged_dict := mergeOverwrite $context_novalues $current_dict.nodeData }} + {{- $merged_dict := merge $current_dict.nodeData $context_novalues }} {{- $_ := set $current_dict "nodeData" $merged_dict }} {{/* Deep copy original daemonset_yaml */}} {{- $_ := set $context.Values "__daemonset_yaml" ($daemonset_yaml | toYaml | fromYaml) }} -- 2.7.4