You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am deploying a helm chart with dependencies using pulumi helm. Pulumi preview fails with a duplicate urn error. I ran with debug and noticed a service account was being created twice.
Other:
To verify this was an issue with subcharts, I ran pulumi preview on each chart independently and pulumi preview passed.
I initially thought the problem was related to using a subchart, but that turned out to be a red herring.
The actual problem here is that the kong chart includes the ServiceAccount twice:
kong/templates/migrations-pre-upgrade.yaml
kong/templates/controller-service-account.yaml
The migrations one includes Helm hooks, which we don't currently support (#555), but you can work around this by removing that resource with a transformation:
constchartName="kong-chart";newk8s.helm.v2.Chart(chartName,{chart: "kong/kong",version: "1.1.0",transformations: [(obj: any)=>{if(obj.kind==="ServiceAccount"&&obj.metadata.name===`${chartName}-kong`){// Omit this resource (https://github.com/pulumi/pulumi-kubernetes/issues/486#issuecomment-527958122)obj.apiVersion="v1"obj.kind="List"obj.items=[];}}]});
Closing out this issue now, but let me know if this doesn't solve your problem.
Problem description
I am deploying a helm chart with dependencies using pulumi helm. Pulumi preview fails with a duplicate urn error. I ran with debug and noticed a service account was being created twice.
To verify this was an issue with subcharts, I ran pulumi preview on each chart independently and pulumi preview passed.
Chart dependency:
version: 1.1.0
repository: https://charts.konghq.com
Errors & Logs
The text was updated successfully, but these errors were encountered: