Hey :wave:, i am new to pulumi and try to understa...
# general
m
Hey 👋, i am new to pulumi and try to understand how can i provide internal (shareable) components within my company for common usecases (like terraform modules). Do i understand correct it is limited to specific programming language, e.g. i have to write in typescript and pull in as npm package? Also, the yaml language SDK does not seem to provide a way to leverage components? Is there something i a missing for this kind of approach? I did not find much information in the docs related to this topic 😞.
b
@millions-artist-91772 Pulumi allows you to create packages https://www.pulumi.com/docs/using-pulumi/pulumi-packages/ A package can be a single language, or you can also define multi language packages: https://www.pulumi.com/blog/pulumiup-pulumi-packages-multi-language-components/
you’re correct that you can’t (yet) define packages in YAML
you can however write packages in TypeScript, Python, Go and consume them from YAML
m
you can however write packages in TypeScript, Python, Go and consume them from YAML
Do you have a example how that works?
b
here’s a multi language package authored in Go: https://github.com/lbrlabs/pulumi-lbrlabs-eks it’s consumed by yaml here: https://github.com/lbrlabs/pulumi-lbrlabs-eks/blob/main/examples/yaml/Pulumi.yaml
m
Interesting, i guess it is discovered and pulled via the pulumi registry in this case? Is the YAML provider depends on the registry? I just wonder how it should work for "private" projects, can this be achieved with the
pulumi plugin install resource ...
? So native plugins/packages are actually based on golang? So much unknowns to learn about the internals of pulumi 😅
b
plugin discovery is done via the pulumi engine, so you build a binary, and install via your chosen package manager. I’m not sure on the support for private registries, but you can host a binary plugin on any object store like an internal s3. You just need to set the path to the plugin here: https://github.com/lbrlabs/pulumi-lbrlabs-eks/blob/main/schema.yaml#L6