hi, how can I unset a default object value in helm...
# kubernetes
c
hi, how can I unset a default object value in helm values? e.g. https://github.com/traefik/traefik-helm-chart/blob/master/traefik/values.yaml#L189 metrics does not have an enable field, but has a default value for Prometheus, the chart handles the case when metrics are not defined, but I can't figure out how to unset in pulumi TS. Tried to set
metrics: {}
,
metrics: ''
,
metrics: null
in values, but none of them helps. Transformations did not help either, because it runs after template generation and I don't want to remove the unnecessary fields one by one.
g
I think a transformation is your answer here, but it means you might need to remove the fields one by one.
c
@gentle-diamond-70147 That would be a pain in the ass because used in multiple places. It would be nice to support this somehow from pulumi.
g
Not sure I follow in terms of "multiple places" - can you elaborate?
c
In the traefik helm chart the
.Values.metrics
condition used in multiple places, e.g.: deployment "ports" section, command-line arguments, etc. That's why I said it's hard to remove from everywhere with transformations, it's possible of course, but wouldn't be a maintainable code (e.g.: a next helm chart version adds more sections based on the same condition)