Skip to content

Commit 4954e04

Browse files
authored
Merge pull request #63 from DNXLabs/idle_timeout_var
add idle_timeout_var and default 400
2 parents 94db318 + e771369 commit 4954e04

File tree

3 files changed

+8
-1
lines changed

3 files changed

+8
-1
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ module "ecs_apps" {
105105
| extra\_certificate\_arns | Extra ACM certificates to add to ALB Listeners | `list(string)` | `[]` | no |
106106
| extra\_task\_policies\_arn | Extra policies to add to the task definition permissions | `list(string)` | `[]` | no |
107107
| fargate\_only | Enable when cluster is only for fargate and does not require ASG/EC2/EFS infrastructure | `bool` | `false` | no |
108+
| idle\_timeout | IDLE time for ALB on seconds. | `number` | `400` | no |
108109
| instance\_types | Instance type for ECS workers | `list(any)` | `[]` | no |
109110
| instance\_volume\_size | Volume size for docker volume (in GB). | `number` | `30` | no |
110111
| instance\_volume\_size\_root | Volume size for root volume (in GB). | `number` | `16` | no |

_variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -384,3 +384,9 @@ variable "code_deploy" {
384384
default = true
385385
description = "Enables CodeDeploy role to be used for deployment"
386386
}
387+
388+
variable "idle_timeout" {
389+
type = number
390+
default = 400
391+
description = "IDLE time for ALB on seconds."
392+
}

alb.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ resource "aws_lb" "ecs" {
1212
aws_security_group.alb[0].id,
1313
]
1414

15-
idle_timeout = 400
15+
idle_timeout = var.idle_timeout
1616

1717
dynamic "access_logs" {
1818
for_each = compact([var.lb_access_logs_bucket])

0 commit comments

Comments
 (0)