sparse-intern-71089
11/01/2021, 2:13 PMbillowy-army-68599
sticky-airline-40485
11/01/2021, 3:07 PM.aws folder
config file:
[profile michael]
region = eu-west-1
credentials file:
[michael]
aws_access_key_id = ###
aws_secret_access_key = ###
In my Pulumi folder, I have two stacks, a dev stack and a prod stack. Both my Pulumi.dev.yaml and Pulumi.prod.yaml files are identical:
config:
aws:profile: michael
aws:region: eu-west-1
Running pulumi up -s dev runs fine, but running pulumi up -s prod gives me the unable to discover AWS AccessKeyID and/or SecretAccessKey errorbillowy-army-68599
aws sts get-caller-identity return?billowy-army-68599
prod stack and readd itsticky-airline-40485
11/01/2021, 3:09 PMwhat doesI get 55###96 arnawsiam::55###96:user/michael.truong AI###SDreturn?aws sts get-caller-identity
sticky-airline-40485
11/01/2021, 3:10 PMcan you remove the profile key from theSorry, what you you mean by read it?stack and readd itprod
sticky-airline-40485
11/01/2021, 3:12 PMpulumi config set aws:profile michael and it adds fine, which is what adds to my confusionbillowy-army-68599
sticky-airline-40485
11/01/2021, 3:14 PMbillowy-army-68599
sticky-airline-40485
11/01/2021, 3:24 PMdev stack, the profile and region are set in the AWS provider for both inputs and outputs, but in prod they aren't
dev stack (excerpt):
{
"urn": "urn:pulumi:dev::app::pulumi:providers:aws::default_4_25_0",
"custom": true,
"id": "###",
"type": "pulumi:providers:aws",
"inputs": {
"profile": "michael",
"region": "eu-west-1",
"version": "4.25.0"
},
"outputs": {
"profile": "michael",
"region": "eu-west-1",
"version": "4.25.0"
}
},
prod stack (excerpt):
{
"urn": "urn:pulumi:prod::app::pulumi:providers:aws::default_4_25_0",
"custom": true,
"id": "###",
"type": "pulumi:providers:aws",
"inputs": {
"version": "4.25.0"
},
"outputs": {
"version": "4.25.0"
}
},
seems to be only one profile in both stacks, but interestingly, in thebillowy-army-68599
up with a valid profile set to fix itsticky-airline-40485
11/01/2021, 3:27 PMpulumi up -s dev works fine but pulumi up -s prod complains, even though they both reference the same (valid) profilesticky-airline-40485
11/01/2021, 3:28 PMbillowy-army-68599
sticky-airline-40485
11/01/2021, 3:33 PMpulumi up -s dev works just fine and it points to the same profilebillowy-army-68599
up isn't working yet, you'll need to have valid credentialssticky-airline-40485
11/01/2021, 3:37 PMsticky-airline-40485
11/01/2021, 3:38 PMbillowy-army-68599
aws sts get-caller-identity and then ensure you can perform AWS operations like aws s3 ls from your current profile
• run a successful pulumi up
• then readd the aws:profile config setting
also make sure you don't have any explicit providers on your resourcessticky-airline-40485
11/01/2021, 4:31 PMsticky-airline-40485
11/02/2021, 10:42 AMAWS_* environment variables directly, this works. I'll file this as an issue as I shouldn't have had to do that