okigan / awscurl

curl-like access to AWS resources with AWS Signature Version 4 request signing.
MIT License
755 stars 94 forks source link

If no credentials are specified, try and retrieve some temporary credentials via STS and the IAM Instance Profile in EC2 #17

Closed gozer closed 7 years ago

gozer commented 7 years ago

If not available, continue attempting to retrieve credentials the same way as before

Fixes #16

okigan commented 7 years ago

This maybe a bit too big of a dependency to add to awscurl, meaning if you got boto one should use "boto way" to make aws requests. awscurl aims to give simpler surface area for making signed aws requests.

For now I'd defer to aws cli suggestion of using temporary credentials (from sts or not) and just pass them to awscurl http://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_temp_use-resources.html#using-temp-creds-sdk-cli

export AWS_ACCESS_KEY_ID=AKIAI44QH8DHBEXAMPLE
export AWS_SECRET_ACCESS_KEY=wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
export AWS_SECURITY_TOKEN=AQoDYXdzEJr...<remainder of security token>

awscurl ...