fix(helm): fix invalid YAML syntax and nil pointer in values.yaml (backport #5990)#6216
Conversation
The template check for domainLabels evaluates empty arrays as truthy, causing an invalid --domainlabels= flag to be generated. Fix by checking that the array is both defined and non-empty before generating the flag. Keep domainLabels: [] in values.yaml for better user experience - users can uncomment example values without needing to add the array syntax back. Signed-off-by: KeshavSoni2511 <keshavsoni2511@gmail.com> (cherry picked from commit 057d55b)
|
/test ci/centos/upgrade-tests-cephfs |
|
/test ci/centos/k8s-e2e-external-storage/1.32 |
|
/test ci/centos/upgrade-tests-rbd |
|
/test ci/centos/mini-e2e-helm/k8s-1.32 |
|
/test ci/centos/k8s-e2e-external-storage/1.33 |
|
/test ci/centos/k8s-e2e-external-storage/1.34 |
|
/test ci/centos/mini-e2e/k8s-1.32 |
|
/test ci/centos/mini-e2e-helm/k8s-1.33 |
|
/test ci/centos/mini-e2e-helm/k8s-1.34 |
|
/test ci/centos/mini-e2e/k8s-1.33 |
|
/test ci/centos/mini-e2e/k8s-1.34 |
|
/test ci/centos/upgrade-tests-cephfs |
|
/test ci/centos/k8s-e2e-external-storage/1.34 |
|
/test ci/centos/k8s-e2e-external-storage/1.32 |
|
/test ci/centos/upgrade-tests-rbd |
|
/test ci/centos/mini-e2e-helm/k8s-1.34 |
|
/test ci/centos/mini-e2e-helm/k8s-1.32 |
|
/test ci/centos/mini-e2e/k8s-1.34 |
|
/test ci/centos/k8s-e2e-external-storage/1.33 |
|
/test ci/centos/mini-e2e/k8s-1.32 |
|
/test ci/centos/mini-e2e-helm/k8s-1.33 |
|
/test ci/centos/mini-e2e/k8s-1.33 |
Merge Queue Status
This pull request spent 10 seconds in the queue, including 1 second running CI. Required conditions to merge
|
The template check for domainLabels evaluates empty arrays as truthy,
causing an invalid --domainlabels= flag to be generated. Fix by
checking that the array is both defined and non-empty before generating
the flag.
Keep domainLabels: [] in values.yaml for better user experience -
users can uncomment example values without needing to add the array
syntax back."
This is an automatic backport of pull request #5990 done by Mergify.