This message was deleted.
# general
s
This message was deleted.
b
agree here. I guess you could append this to the default transformations here? https://github.com/pulumi/pulumi-kubernetes/blob/master/pack/nodejs/helm.ts#L97
👍 1
g
exactly.
here’s the transformation that works for me:
Copy code
transformations: [
    manifest => {
      manifest.metadata.namespace = namespace;
    }
  ]
created a dedicated github issue for this: https://github.com/pulumi/pulumi-kubernetes/issues/217
c
@glamorous-printer-66548 @billowy-army-68599 my understanding is that this is not true. I could be wrong-- not a helm expert. Will take a look.
g
not a helm expert either, but my understanding is that
helm install
does that transformation whereas
helm template
does not. Since I assume most users are used to using
helm install
I would prefer staying closer to `helm install`’s behaviour if possible.
c
Ah
That could well be true
Probably what's happening there is it's using client go's deploy to name space feature
g
yeah probably
c
We could do that here but it will take some plumbing.
This is much easier than re name spacing everything.
g
i see
c
Because not everything is namespaced
g
ah true, forgot about clusterroles etc. ..
c
That is to say rewriting namespaces is hard in general
Right.
So, doable.
g
Anyways you should either use go-clients deploy to namespace feature or explicitly document this limitation in pulumi’s helm integration. I’m sure I’m not the first or last person to stumble upon this gotcha 🙂 . I actually browsed a few helm charts to see how often that Namespace attribute is templated and it’s surprisingly often not, so a lot of helm charts will see that behaviour.
c
100% agree
We will do this
👍 2