aws-toolkit-eclipse icon indicating copy to clipboard operation
aws-toolkit-eclipse copied to clipboard

Toolkit does not use configuration file

Open dennispost opened this issue 7 years ago • 6 comments

It seems to be the case that the Eclipse toolkit does not use the configuration file located at ~/.aws/config. Only credentials configured in ~/.aws/credentials are used.

Therefore using a specific role configured as role_arn=arn:aws:iam::123456789123:role/RoleName is not possible. On CLI it is possible to use such config profiles.

Config file:

[profile myProfile]
role_arn=arn:aws:iam::123456789123:role/RoleName
region=eu-central-1
source_profile=myCredentialProfile

Credentials file:

[myCredentialProfile]
aws_access_key_id=XXXXXXXXXXXXXXXX
aws_secret_access_key=******************************************

dennispost avatar Oct 05 '17 11:10 dennispost

Thanks for calling out this feature request. Yes you are right, the AWS Toolkit for Eclipse doesn't support the AWS CLI's ~/.aws/config file for profiles with assume role. We'll add this to our backlog and let you know once this feature is out.

zhangzhx avatar Oct 09 '17 07:10 zhangzhx

This is really important and needed. Hope it would be developed and delivered as soon as possible. waiting for it ..

swaroop477 avatar Jul 10 '18 17:07 swaroop477

Any news on this? This also needed for my team as well

agutierrezl avatar Aug 20 '18 12:08 agutierrezl

Also needed here, any feedback about this issue?

sergiolecuona avatar Oct 30 '18 09:10 sergiolecuona

We also need this.

eschulma avatar Feb 26 '20 03:02 eschulma

Found a solution! Apparently it works if you add "source_profile" and "role_arn" into the desired profile in the credentials file.

Taking the example from the original post, this is a working example (tested for both AWS toolkit for Eclipde and VSCode) :

Credentials file:

[myCredentialProfile]
aws_access_key_id=XXXXXXXXXXXXXXXX
aws_secret_access_key=******************************************
role_arn=arn:aws:iam::123456789123:role/RoleName
source_profile=globalCredentialsprofile

[globalCredentialsprofile]
aws_access_key_id=XXXXXXXXXXXXXXXX
aws_secret_access_key=******************************************

EDIT: After checking, I believe you don't even need the "aws_access_key_id" and "aws_secret_access_key" in the profile that contains the "role_arn" and the "source_profile"

anaelsh avatar Aug 13 '20 15:08 anaelsh