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

full-artist-27215

11/03/2021, 1:27 PM
🤔 This has always "just worked" for me. Is
AWS_PROFILE
set in your environment?
c

clever-painter-96148

11/03/2021, 2:14 PM
Yes. Here what I did: 1. Authenticate:
Copy code
$ aws sso login --profile foo
2. Validate credentials:
Copy code
$ aws sts get-caller-identity --profile foo
3. Run pulumi:
Copy code
$ AWS_PROFILE=foo pulumi pre
Pulumi fails with this error:
Copy code
unable to discover AWS AccessKeyID and/or SecretAccessKey - see <https://pulumi.io/install/aws.html> for details on configuration
f

full-artist-27215

11/03/2021, 2:41 PM
Are you configuring your AWS provider in any special way in your stack YAML file? Or are you creating one manually in your main Pulumi program? I'm not quite sure what's going on here 😕
c

clever-painter-96148

11/03/2021, 2:49 PM
Nope. I simply specify the region:
Copy code
$ cat Pulumi.dev.yaml 
config:
  aws:region: eu-west-1
BTW I also tried to set aws:profile in there. Same results.
f

full-artist-27215

11/03/2021, 2:57 PM
What version of Pulumi and
pulumi_aws
are you using?
c

clever-painter-96148

11/03/2021, 3:03 PM
Copy code
$ grep @pulumi/ package.json 
    "@pulumi/aws": "^4.25.0",
    "@pulumi/pulumi": "^3.16.0"
Copy code
$ pulumi version
v3.16.0
f

full-artist-27215

11/03/2021, 3:28 PM
That matches with what I'm using... I'm not sure what's going on here, then; sorry 🙁
c

clever-painter-96148

11/03/2021, 3:30 PM
Thanks for trying 🙂
f

full-artist-27215

11/03/2021, 3:32 PM
good luck!
f

faint-table-42725

11/03/2021, 5:26 PM
Mentioned this in the other thread, but one thing to maybe look at is
AWS_SDK_LOAD_CONFIG
and seeing if you have that env var set to a truthy value as if your profile is defined in
~/.aws/config
I believe you’ll need that set to pick it up
c

clever-painter-96148

11/03/2021, 5:33 PM
I replied on the other thread - let's focus the discussion on that one. Thanks! 🙂