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
In both Python and Golang, the exports are programmatic - eg, in Python, you call pulumi.export('public_ip', server.public_ip).
For <reasons>, I could do with doing a similar sort of thing in TypeScript - is there any way of getting TS to create outputs with a pulumi method rather than the export const public_ip = server.public_up?
The text was updated successfully, but these errors were encountered:
There's no way directly that I know of. Depending on what you're trying to do, an alternative to using the export syntax is to have a top-level function return the outputs as in the second example shown on: https://www.pulumi.com/docs/intro/languages/javascript/#entrypoint
Is it possible to add this to the roadmap? I'm happy to have a look at adding this. The reason being this work around is possible but for some use cases not ideal. My example is I am creating a shared component which creates a container app and a managed certificate in azure. It has a bit of a weird circular dependency so we have to know if the certificate has already been created already or not (and use that to create the definition of the container app). This is managed by creating an output with the certificate id (if its created). Ideally the custom component could create an output in the constructor so the consumer of that component doesn't have to care.
In both Python and Golang, the exports are programmatic - eg, in Python, you call
pulumi.export('public_ip', server.public_ip)
.For
<reasons>
, I could do with doing a similar sort of thing in TypeScript - is there any way of getting TS to create outputs with a pulumi method rather than theexport const public_ip = server.public_up
?The text was updated successfully, but these errors were encountered: