I have a python script that loops through all of the AWS accounts we have and lists the EC2 instances in each one.
I want to turn it into an AWS Lambda function. But I can't figure out how to pull the AWS credentials that would allow me to list the servers in all the accounts.
How can I achieve this in AWS Lambda?
When you create lambda you have so specify a role In IAM you can attach required permission to a lambda role.
If you want to use some specific set of credentials in a file, you can utilize AWS Systems Manager to retrieve credentials. Though, I would recommend role on lambda
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.