Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"--Profile" option fails when using roles instead of Secret/ID #264

Closed
rszuster opened this issue Sep 10, 2018 · 5 comments
Closed

"--Profile" option fails when using roles instead of Secret/ID #264

rszuster opened this issue Sep 10, 2018 · 5 comments

Comments

@rszuster
Copy link

Issue type

  • Bug report

cli53 version (cli53 --version)

cli53 version 0.8.12

OS / Platform

Windows

Steps to reproduce

I work on multiple accounts and i use roles for cross-account operations using a single set of credentials.
The credentials/config files look something like this:

[default]
aws_access_key_id=<ID>
aws_secret_access_key=<SECRET>

[<profilename>]
role_arn=arn:aws:iam::<ACCT>:role/<ROLE>
source_profile=default

That configuration should be correct, it works just fine with AWS CLI, Powershell, etc, but cli53 throws the error shown below.

Expected behaviour

cli53 list --profile <profilename>
ID             Name                 Record count Comment
<ID>           <name>               <records>

Actual behaviour

cli53 list --profile <profilename>
Error: SharedCredsAccessKey: shared credentials <profilename> in C:\Users\<user>\.aws\credentials did not contain aws_access_key_id
caused by: error when getting key of section '<profilename>': key 'aws_access_key_id' not exists
@barnybug
Copy link
Owner

see: aws/aws-sdk-go#472

@barnybug
Copy link
Owner

also: #254
I don't have the time to test this setup, so if you could and provide further feedback.

@rszuster
Copy link
Author

Setting the environment variable and rebuilding does yield a working binary.

set AWS_SDK_LOAD_CONFIG=1
go get github.com/barnybug/cli53/cmd/cli53

@gergnz
Copy link

gergnz commented Jan 8, 2019

I'm not sure that AWS_SDK_LOAD_CONFIG is required anymore. (there is some discussion in the go sdk community regarding it).

It looks like cli53 just needs to be built against a recent version of the SDK maybe? is it possibly to do a new release with an update SDK version?

@barnybug
Copy link
Owner

barnybug commented Jan 9, 2019

Yep, just required a new release on our part - up here:
https://github.com/barnybug/cli53/releases/tag/0.8.13

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants