How to specify aws credential profile
Closed this issue · 2 comments
lc-rezende commented
Hi there. I have multiple profiles in my /.aws/credentials and by default it uses the [default] profile. How can I specify another credential profile in command-line?
Thanks!
c-nichols commented
Hi Lucas, I don't have multiple profiles set up to test this, but you should be able to use the environment variable AWS_PROFILE
as shown here: https://docs.aws.amazon.com/cli/latest/userguide/cli-multiple-profiles.html
To utilize the secondary profile for the duration of your terminal session, use:
export AWS_PROFILE=user2
And then run your commands.
To utilize the secondary profile for only the Spectrify command, prepend the AWS_PROFILE
assignment to the command:
AWS_PROFILE=user2 spectrify .....
Does that work for you?
lc-rezende commented
Thank you @c-nichols ! Worked fine.
All the best.