https://pulumi.com logo
s

strong-match-67698

08/30/2023, 3:27 PM
Hi, we share resources between some of our stacks. And for the most parts it works well. We create a resource in one stack and then reference it in another, like (.NET):
var vnet = V20230201.VirtualNetwork.Get("vnet", baseStackRef.RequireOutput("VNetId").Cast<string>());
However, the same does not seem to work with the ComponentResources that we create.
var myComponentResource = MyComplexResource.Get(...)
wont work as the method isn't there (in ComponentResource base class). Is there any way to reference component resources between stacks?