aws lambda function getting access denied when getObject from s3

后端 未结 12 1579
离开以前
离开以前 2020-12-08 06:44

I am getting an acccess denied error from S3 AWS service on my Lambda function.

This is the code:

// dependencies
var async = require(\'async\');
var         


        
12条回答
  •  春和景丽
    2020-12-08 07:08

    Your Lambda does not have privileges (S3:GetObject).

    Go to IAM dashboard, check the role associated with your Lambda execution. If you use AWS wizard, it automatically creates a role called oneClick_lambda_s3_exec_role. Click on Show Policy. It should show something similar to the attached image. Make sure S3:GetObject is listed.

提交回复
热议问题