https://pulumi.com logo
#general
Title
# general
c

cool-egg-852

03/16/2020, 9:44 PM
How do I use the
kong
helm charts that do something like:
Copy code
{{- if .Capabilities.APIVersions.Has "<http://admissionregistration.k8s.io/v1|admissionregistration.k8s.io/v1>" }}
apiVersion: <http://admissionregistration.k8s.io/v1|admissionregistration.k8s.io/v1>
{{- else }}
apiVersion: <http://admissionregistration.k8s.io/v1beta1|admissionregistration.k8s.io/v1beta1>
{{- end }}
The issue is that
pulumi
doesn’t seem to have a way to make that first condition false.
g

gorgeous-egg-16927

03/16/2020, 10:31 PM
You should be able to set the
apiVersions
flag on the
Chart
resource to control this. https://www.pulumi.com/docs/reference/pkg/nodejs/pulumi/kubernetes/helm/v2/#ChartOpts-apiVersions
c

cool-egg-852

03/16/2020, 10:31 PM
I filed an issue because it doesn’t seem to work that way
As far as I can tell,
apiVersions
allows you to add in an API, not override the version
2 Views