Allow EC2 role credentials during function deployment
See original GitHub issueMy build server is an EC2 instance with a role that allows it to do everything it needs to perfrom deployments.
The dotnet lambda deploy-function command doesn’t understand this scenario. It assumes you either specify a credential profile or, if you don’t, it uses credentials from environment variables. It would be super nifty if it supported using role credentials as well.
It’s possible it already supports this and I’m doing something wrong. I tried removing the “profile” value from my aws-lambda-tools-defaults.json file and didn’t specify a profile on the command line. I wound up with this error message:
Error determining region for bucket dgi.deploy-lambda: Error determining region for bucket dgi.deploy-lambda: Access Denied
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Using an IAM role to grant permissions to applications ...
When you use a role, you don't have to distribute long-term credentials (such as sign-in credentials or access keys) to an Amazon EC2...
Read more >IAM roles for Amazon EC2 - Amazon Elastic Compute Cloud
To create an IAM role using the IAM console · In the navigation pane, choose Roles then choose Create role. · On the...
Read more >🔥Let's Do DevOps: Assuming an IAM role from an EC2 ...
Roles: An IAM role is a bucket of permissions. The permissions it contains are not “within” the role, but rather are described in...
Read more >How do I assume an IAM role using the AWS CLI?
Use an IAM role by creating a profile in the ~/.aws/config file. For more information, see Using an IAM role in the AWS...
Read more >IAM Credentials - SST docs
IAM Credentials. SST uses your AWS credentials to run the Live Lambda Development environment and deploy your app.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Version 2.1.4 was just released with this fix to continuing looking for credentials when the profile can not be found.
I have made that change in the dev branch to go out with the next release https://github.com/aws/aws-extensions-for-dotnet-cli/commit/68e7329f587b18eb4ce6a7fd84c1b010eec83aa4