Is there any to use a `kubernetes.yaml.v2.ConfigFi...
# kubernetes
m
Is there any to use a
kubernetes.yaml.v2.ConfigFile
with a templated file? I want to use a manifest that I already have as jinja2 template . I know I can use
transformations
but I would prefer to use the jinja2. I tried to pass an output with a
StringAsset
to
file=xxx
but It's not supported (opened a feature request) . Any other idea?
m
The file is parsed by the provider from disk (relevant code, implementation of Parse), so passing an in-memory file object (e.g., through StringIO) is not an option. To me, it looks like the best and most straightforward option is to generate (temporary) files on disk and pass their paths to ConfigFile.
d
Use ConfigGroup for yaml strings
🙌 1
💡 1
m
I see now Literal YAML string in kubernets.yaml.v2.ConfigGroup https://www.pulumi.com/registry/packages/kubernetes/api-docs/yaml/v2/configgroup/
d
Thanks
m
thanks to you! you saved me a lot of time.