Skip to content

Ordering of placement_strategy  #1466

Closed
@atsushi-ishibashi

Description

@atsushi-ishibashi

How about supporting the order of placement strategy?
https://github.com/terraform-providers/terraform-provider-aws/blob/48fdbc0997746c9c226d36bf358d8884b176c0da/aws/resource_aws_ecs_service.go#L106
According to aws docs, maybe the order is associated with that of "placementStrategy" list.

I'd like to configure like AZ Balance Spread provided by AWS console so I wrote the codes below. But placement_strategy is set as TypeSet, so I couldn't create placement_strategy of AZ Balance Spread.

resource "aws_ecs_service" "hoge" {
  placement_strategy {
    type  = "spread"
    field = "instanceId"
  }

  placement_strategy {
    type  = "spread"
    field = "attribute:ecs.availability-zone"
  }
}

So I propose that adding a order key to placement_strategy or applying TypeList to placement strategy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugAddresses a defect in current functionality.service/ecsIssues and PRs that pertain to the ecs service.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions