With the new structure for specifying env vars in the template we are experiencing issues. We have a deployment with env var that is either a bool or a number. So normally we specify it as:
env:
- name: TEST
value: "1"
When that passes through helmify we get a template that looks like this:
env:
- name: TEST
value: {{ .Values.controllerManager.manager.env.test
}}
When the template is parsed, the value "1" gets replace but then the resulting yaml is:
env:
- name: TEST
value: 1
This is invalid and is rejected by Kubernetes since the env value must always be a string. The same issue would occur if the env value is a boolean.
This PR is an attempt to fix the problem. I already tested that this approach fixes our issue but feel free to adjust it if needed
With the new structure for specifying env vars in the template we are experiencing issues. We have a deployment with env var that is either a bool or a number. So normally we specify it as:
When that passes through
helmify
we get a template that looks like this:When the template is parsed, the value "1" gets replace but then the resulting yaml is:
This is invalid and is rejected by Kubernetes since the env value must always be a string. The same issue would occur if the env value is a boolean.
This PR is an attempt to fix the problem. I already tested that this approach fixes our issue but feel free to adjust it if needed