https://pulumi.com logo
#aws
Title
# aws
a

ambitious-father-68746

10/08/2020, 1:56 PM
I'm getting a very weird behaviour. I have many AWS accounts and in Pulumi I create multiple providers, one for each.
pulumi up
is working fine. Unfortunately today I'm getting lots of permission error with
pulumi regresh
, which wasn't happening before, as if it's trying to use the main AWS identity without assuming any roles for the other AWS accounts. I'm using the latest versions of Pulumi and pulumi-aws and I didn't update any of the components of my project. Is anyone experiencing the same thing?
b

broad-dog-22463

10/08/2020, 2:08 PM
Hi @ambitious-father-68746 How are you cnfiguring your credentials for the provider?
a

ambitious-father-68746

10/08/2020, 2:12 PM
I use AWS SSO to link the accounts with my main account. In Pulumi I just do this:
Copy code
provider = pulumi_aws.Provider(account_name,assume_role={"role_arn": assume_role}, region=region)
And then reference the provider for each resource.
b

broad-dog-22463

10/08/2020, 2:13 PM
what is
account_name
? Is it set via pulumi config set aws:accountName ?
a

ambitious-father-68746

10/08/2020, 2:14 PM
No, it's just a variable that I pass through, just an identifier
I have to clarify that
pulumi up
continues to work properfy, only
pulumi refresh
is breaking.
I have a feeling this is related to https://github.com/pulumi/pulumi-aws/issues/1158, so I'll comment there and see if people can replicate
I had AWS_DEFAULT_REGION environment variable set. If I remove it, now I get the following error:
Copy code
error: failed to load checkpoint: blob (key ".pulumi/stacks/prod.json") (code=Unknown): MissingRegion: could not find region configuration
I think it's too much of a coincidence that my potential region problems are appearing at the same time as other people's complaints
b

broad-dog-22463

10/08/2020, 2:32 PM
yeah this is a problem with v3.6.0