From 1bafbdbfde8af57fba978c970a2171b40695327a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20B=C3=A9gin?= Date: Tue, 4 May 2021 10:12:38 -0400 Subject: [PATCH] remove list functions in favor of sqaure brackets MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Samuel Bégin --- workers_launch_template.tf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/workers_launch_template.tf b/workers_launch_template.tf index 83ea1f6da5d..2e97e2657ce 100644 --- a/workers_launch_template.tf +++ b/workers_launch_template.tf @@ -33,7 +33,7 @@ resource "aws_autoscaling_group" "workers_launch_template" { dynamic "mixed_instances_policy" { iterator = item - for_each = (lookup(each.value, "override_instance_types", null) != null) || (each.value.on_demand_allocation_strategy != null) ? list(each.value) : [] + for_each = (lookup(each.value, "override_instance_types", null) != null) || (each.value.on_demand_allocation_strategy != null) ? [each.value] : [] content { instances_distribution { @@ -65,7 +65,7 @@ resource "aws_autoscaling_group" "workers_launch_template" { dynamic "launch_template" { iterator = item - for_each = (lookup(each.value, "override_instance_types", null) != null) || (each.value.on_demand_allocation_strategy != null) ? [] : list(each.value) + for_each = (lookup(each.value, "override_instance_types", null) != null) || (each.value.on_demand_allocation_strategy != null) ? [] : [each.value] content { id = aws_launch_template.workers_launch_template[each.key].id @@ -223,7 +223,7 @@ resource "aws_launch_template" "workers_launch_template" { } dynamic "instance_market_options" { - for_each = lookup(each.value, "market_type", null) == null ? [] : list(lookup(each.value, "market_type", null)) + for_each = lookup(each.value, "market_type", null) == null ? [] : [lookup(each.value, "market_type", null)] content { market_type = instance_market_options.value }