https://pulumi.com logo
#general
Title
# general
s

stocky-petabyte-29883

02/23/2022, 1:51 PM
Hey Guys, If I am consuming output values from my current stack in a project, how would this behave when I am redeploying this to a brand new environment where the output will be only created during the same execution? Will pulumi wait for that output to be available and use that or will it fail?
l

little-cartoon-10569

02/23/2022, 7:52 PM
It will fail if you use
require...
and return
undefined
if you use
get...
.
s

stocky-petabyte-29883

02/23/2022, 8:55 PM
How would we approach this though if we need output of one resource to create another?
l

little-cartoon-10569

02/23/2022, 8:59 PM
You use the outputs of the resources, not of the stack.
So if you want to output a bucket name from a stack, and use that bucket name in another resource, don't use the exported variable, use the bucket name directly.
👍 1
2 Views