Is there a way for a stack to contribute to the re...
# azure
p
Is there a way for a stack to contribute to the resource of another stack? For example, a subscription to an Event Grid topic, where the topic itself is owned by another stack. Another example might be a rule / backend on a Front Door instance.
f
I have a feeling you'll end up with inconsistent state, as you'll have modified something that the first stack think it owns, so it's drifted. Is the event subscription not it's own resource?
You could just Output the topic endpoint from one stack, and use a `StackReference`in the other stack to pull in the the endpoint. https://www.pulumi.com/docs/intro/concepts/stack/#stackreferences
p
Good to know for stack references, but you were right the subscription is actually it's own resource. Thanks!