Hello How you y'all use pulumi on a multi account...
# general
a
Hello How you y'all use pulumi on a multi account environment with AWS? So far I have my root account Then I have my • production account • development account The idea is to re use my code across these account environments
l
You will use a single project (set of code) and multiple stacks (configuration sets). Each stack will define its own credentials. For most projects, you might define the AWS profile name in the stack configuration, and each profile (defined in the normal AWS way, in ~/.aws/config) would point at a different account.
For projects that needs to talk to more than one account (e.g. you're setting up VPC peering), you would use more than one AWS provider. Each provider's configuration would have to be defined separately within a single stack configuration. That is, instead of the name
aws:profile: prod
or similar, you might have
myproject:prodprofile: prod
and
myproject:devprovile: dev
There's a heap of other ways to do it. The full range of AWS credential configuration is supported by Pulumi.
a
is this how ir works for you?
l
I administer many projects with all sorts of different ways of doing it 🙂 The profile-per-stack is probably the easiest. And it works nicely with SSO without changing Pulumi code.