Skip to content

agoose77/reproducer-helm-merge-changes

Repository files navigation

Demo of Helm merging behaviour

Helm null handling has regressed. It's noticeable in Test 2.

Each test can be run by Helm 3.17.0, and Helm 4.1.1. Compare the outputs!

0. Define helpers

alias helm-317='podman run --rm -it -v $PWD:/app -w /app "alpine/helm:3.17.0"'
alias helm-411='podman run --rm -it -v $PWD:/app -w /app "alpine/helm:4.1.1"'

1. Overriding chart values (in parent chart)

Warning

This is the test that has regressed.

  • The child chart defines a config section (empty mapping) in values.yaml.
  • The parent chart defines a config value in values.yaml
  • The custom next-values.yaml overrides the parent config key with null
(
  cd nested-chart-values-override
  helm-317 template . --values=./next-values.yaml 
  helm-411 template . --values=./next-values.yaml 
)

2. Overriding sibling values (in parent chart)

  • The child chart defines a config section (empty mapping) in values.yaml.
  • The parent chart defines an arbitrary key in values.yaml
  • The custom next-values-1.yaml and next-values-2.yaml define a different key with a non-null, and null value, respectively.
(
  cd nested-chart-siblings-override
  helm-317 template . --values=./next-values-1.yaml --values=./next-values-2.yaml 
  helm-411 template . --values=./next-values-1.yaml --values=./next-values-2.yaml 
)

3. Overriding chart values (in single chart)

  • The chart defines a config section with a default value in values.yaml.
  • The custom next-values.yaml overrides the chart config key with null
(
  cd single-chart-values-override
  helm-317 template . --values=./next-values.yaml 
  helm-411 template . --values=./next-values.yaml
)

4. Overriding sibling values (in single chart)

  • The chart defines a config section (empty mapping) in values.yaml.
  • The custom next-values-1.yaml and next-values-2.yaml define a different key with a non-null, and null value, respectively.
(
  cd single-chart-siblings-override
  helm-317 template . --values=./next-values-1.yaml --values=./next-values-2.yaml 
  helm-411 template . --values=./next-values-1.yaml --values=./next-values-2.yaml 
)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors