Move delete key to coalesceValues and switch to cover all YAML null syntax options

reviewable/pr2648/r2
Scott Rigby 8 years ago
parent d4e03f1e15
commit 413a01b34b

@ -278,6 +278,19 @@ func coalesceValues(c *chart.Chart, v map[string]interface{}) (map[string]interf
}
for key, val := range nv {
// If the value is YAML null, remove the value's key.
// This allows Helm's various sources of values (value files or --set) to
// remove incompatible keys from any previous chart, file, or set values.
// ref: http://www.yaml.org/spec/1.2/spec.html#id2803362
switch val {
case "null":
case "Null":
case "NULL":
case "~":
delete(v, key)
continue
}
if _, ok := v[key]; !ok {
// If the key is not in v, copy it from nv.
v[key] = val

Loading…
Cancel
Save