Skip to content

Commit 4aef8be

Browse files
author
Mark Roth
committed
added a timeout parameter to the aws_lambda_function resource
1 parent e66a62a commit 4aef8be

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,7 @@ resource "aws_lambda_function" "api_lambda" {
247247
handler = var.handler
248248
runtime = var.runtime
249249
publish = true
250+
timeout = var.timeout
250251

251252
dynamic "environment" {
252253
for_each = var.environment_variables != null ? [1] : []

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,4 +109,10 @@ variable "use_codedeploy" {
109109
type = bool
110110
description = "If true, CodeDeploy App and Deployment Group will be created and TF will not update alias to point to new versions of the Lambda (becuase CodeDeploy will do that)."
111111
default = false
112+
}
113+
114+
variable "timeout" {
115+
type = number
116+
description = "Timeout (in seconds) for lambda. Defaults to 3 (terraform default"
117+
default = 3
112118
}

0 commit comments

Comments
 (0)