Any general tips for sharing high level definition...
# general
c
Any general tips for sharing high level definitions (e.g. VPC) across multiple repos / projects? E.g. one VPC may have several deployments in it, from different code bases. I think this can simply be done with internal NPM modules. But I am wondering if there is another, maybe a better, way?
w
If you have a VPC that needs to be used in several apps, you can split into separate stacks, one for the VPC layer and others for each app. Then use StackReference from the apps to refer to the outputs of the VPC. See https://www.pulumi.com/docs/intro/concepts/organizing-stacks-projects/. If you have code (not resources) that you want to share across multiple apps (like you have a pattern for how those apps should configure k8s resources), then you could definitely use shared NPM modules for that.
c
Cool, thanks!