File tree Expand file tree Collapse file tree 2 files changed +16
-4
lines changed
Expand file tree Collapse file tree 2 files changed +16
-4
lines changed Original file line number Diff line number Diff line change @@ -18,10 +18,8 @@ resource "aws_ecs_service" "main" {
1818 deployment_minimum_healthy_percent = " ${ var . deployment_min_healthy_percent } "
1919 deployment_maximum_percent = " ${ var . deployment_max_percent } "
2020
21- ordered_placement_strategy = {
22- type = " spread"
23- field = " instanceId"
24- }
21+ ordered_placement_strategy = [" ${ var . ordered_placement_strategies } " ]
22+ placement_constraints = [" ${ var . placement_constraints } " ]
2523
2624 load_balancer {
2725 target_group_arn = " ${ aws_alb_target_group . main . id } "
Original file line number Diff line number Diff line change @@ -105,3 +105,17 @@ variable "scale_down_cooldown_seconds" {
105105 default = 60
106106 description = " Number of seconds after the alarm that the scale DOWN should happen."
107107}
108+
109+ variable "ordered_placement_strategies" {
110+ type = " list"
111+ default = [{
112+ type = " spread"
113+ }]
114+ }
115+
116+ variable "placement_constraints" {
117+ type = " list"
118+ default = [{
119+ type = " distinctInstance"
120+ }]
121+ }
You can’t perform that action at this time.
0 commit comments