sparse-intern-71089
06/01/2022, 10:29 PMlittle-cartoon-10569
06/01/2022, 10:37 PMlittle-cartoon-10569
06/01/2022, 10:39 PMif (stackName == pulumi.getStack())
) and then continue
.sticky-answer-6826
06/02/2022, 12:33 AMpulumi preview
or pulumi
up
and as the stack is being evaluated to know what to do (create/delete resources), I can't call a new StackReference on the same stack. That's where the collision happens.little-cartoon-10569
06/02/2022, 1:18 AMlittle-cartoon-10569
06/02/2022, 1:20 AMsticky-answer-6826
06/02/2022, 3:04 AMpulumi preview
because the internal state of this preview already had this stack reference called:
for (config of configs) {
const stack = new pulumi.StackReference(stackInOtherProject);
// exits here with Duplicate resource URN error
const outputVal = await stack.requireOutputValue(‘myVal’);
// some code here that is reached by config[0] but not config[1]
}
little-cartoon-10569
06/02/2022, 3:32 AMNo matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.
Powered by