S3 trigger configuration


I'm trying to configure a lambda S3 trigger for an existing bucket, but I'm getting the following error in Cloud Formation:

Unable to validate the following destination configurations (Service: Amazon S3; Status Code: 400; Error Code: InvalidArgument; Request ID: 0VZC1XMQ684D3764; S3 Extended Request ID: 2K+TABm48cA8QthjioLmNW2duzYoj3wtL/LAI6K1cO8YauBuNXKDs/fUSVxvux/zMZhDxbBR3/g=; Proxy: null)

Seems to be something related to lambda permission, but I have already setted the invoke permission.

YML especifications:

Lambda Invoke Permission (Already setted)

   Type: 'AWS::Lambda::Permission'
     FunctionName: !GetAtt
       - LambdaFunction
       - Arn
     Action: lambda:InvokeFunction
     Principal: s3.amazonaws.com
     SourceAccount: !Ref 'AWS::AccountId'
     SourceArn: !Ref LambdaARN

AWS::S3::Bucket Notification (Here where error occurs)

      - Event: 's3:ObjectCreated:*'
        Function: !Ref LambdaARN
  • I find out that this error happened because of yml file indentation, I tried removing spaces in the event tag and it worked.

1개 답변

Hello, Here's a direct link to the same error and the possible causes as per your use-case.

Link -- https://aws.amazon.com/premiumsupport/knowledge-center/unable-validate-destination-s3/ -- [1]

profile pictureAWS
지원 엔지니어
답변함 2년 전
  • I had a look in this link, I'm trying to use lambda instead SNS notification. As additional information, the invoke permission is already set in another cloud formation stack, the error occurs when I try to include the bucket notification statement.

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠