Skip to content

Commit

Permalink
Merge pull request #50 from FloRul/feature/cognito-auth
Browse files Browse the repository at this point in the history
Update lambda permission statement_id to include API Gateway path and…
  • Loading branch information
FloRul authored Feb 25, 2024
2 parents a96d8a6 + b830091 commit 1ca1196
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion terraform/modules/api_gateway/lambda_integration/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ resource "aws_api_gateway_integration" "api_gateway_integration" {
}

resource "aws_lambda_permission" "lambda_permission" {
statement_id = "AllowExecutionFromAPIGateway-${var.lambda_function_name}"
statement_id = "AllowExecutionFromAPIGateway-${var.lambda_function_name}-${var.api_gateway_path_part}-${var.api_gateway_http_method}"
action = "lambda:InvokeFunction"
function_name = var.lambda_function_name
principal = "apigateway.amazonaws.com"
Expand Down

0 comments on commit 1ca1196

Please sign in to comment.