I have a pulumi Kubernetes namespace. I deploy a H...
# kubernetes
l
I have a pulumi Kubernetes namespace. I deploy a Helm chart via Pulumi and afterwards want access to one of the resources. I use
chart.getResource("v1/Service, mynamespace.metadata.name, "my-service")
in my code to get access to the service resource, but this doesn’t seem to work because the namespace needs to be a
string
, not an
Output
. How can I get the string the pulumi way? I tried with
mynamespace.metadata.name.apply(value => +value)
but that didn’t work.
b
you can only use it within the apply handler
Copy code
mynamespace.metadata.name.apply(x => chart.getResource("", x, "")
👍🏼 1