Skip to content

Commit 9f13397

Browse files
authored
feat: Add function_url_auth_type option to aws_lambda_permission (#625)
1 parent 520c845 commit 9f13397

File tree

1 file changed

+16
-14
lines changed

1 file changed

+16
-14
lines changed

main.tf

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -280,13 +280,14 @@ resource "aws_lambda_permission" "current_version_triggers" {
280280
function_name = aws_lambda_function.this[0].function_name
281281
qualifier = aws_lambda_function.this[0].version
282282

283-
statement_id_prefix = try(each.value.statement_id, each.key)
284-
action = try(each.value.action, "lambda:InvokeFunction")
285-
principal = try(each.value.principal, format("%s.amazonaws.com", try(each.value.service, "")))
286-
principal_org_id = try(each.value.principal_org_id, null)
287-
source_arn = try(each.value.source_arn, null)
288-
source_account = try(each.value.source_account, null)
289-
event_source_token = try(each.value.event_source_token, null)
283+
statement_id_prefix = try(each.value.statement_id, each.key)
284+
action = try(each.value.action, "lambda:InvokeFunction")
285+
principal = try(each.value.principal, format("%s.amazonaws.com", try(each.value.service, "")))
286+
principal_org_id = try(each.value.principal_org_id, null)
287+
source_arn = try(each.value.source_arn, null)
288+
source_account = try(each.value.source_account, null)
289+
event_source_token = try(each.value.event_source_token, null)
290+
function_url_auth_type = try(each.value.function_url_auth_type, null)
290291

291292
lifecycle {
292293
create_before_destroy = true
@@ -299,13 +300,14 @@ resource "aws_lambda_permission" "unqualified_alias_triggers" {
299300

300301
function_name = aws_lambda_function.this[0].function_name
301302

302-
statement_id_prefix = try(each.value.statement_id, each.key)
303-
action = try(each.value.action, "lambda:InvokeFunction")
304-
principal = try(each.value.principal, format("%s.amazonaws.com", try(each.value.service, "")))
305-
principal_org_id = try(each.value.principal_org_id, null)
306-
source_arn = try(each.value.source_arn, null)
307-
source_account = try(each.value.source_account, null)
308-
event_source_token = try(each.value.event_source_token, null)
303+
statement_id_prefix = try(each.value.statement_id, each.key)
304+
action = try(each.value.action, "lambda:InvokeFunction")
305+
principal = try(each.value.principal, format("%s.amazonaws.com", try(each.value.service, "")))
306+
principal_org_id = try(each.value.principal_org_id, null)
307+
source_arn = try(each.value.source_arn, null)
308+
source_account = try(each.value.source_account, null)
309+
event_source_token = try(each.value.event_source_token, null)
310+
function_url_auth_type = try(each.value.function_url_auth_type, null)
309311

310312
lifecycle {
311313
create_before_destroy = true

0 commit comments

Comments
 (0)