How to export nested outputs from a stack #11621
Unanswered
jesseduffield
asked this question in
Pulumi in Practice
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
One of the ways to export outputs from a pulumi project is by exporting a function which returns an object of outputs:
Say that I want to return nested outputs. How should this be done? Should I try to keep things flat e.g.:
Or should I return nested objects?
With the object approach, I'm not able to import into another project via
stackReference.requireOutput('foo.a')
, and when I usestackReference.requireOutput('foo')
, it's not obvious how to actually pull out the things I need.Thanks!
BTW I searched for 'nested outputs' in both issues and discussions: there were no matches in discussions and the issue I found seemed language-specific.
Beta Was this translation helpful? Give feedback.
All reactions