From 43d19be7c94d41a9a53052ba1a79055f0491c865 Mon Sep 17 00:00:00 2001 From: iycbell Date: Thu, 14 Mar 2024 15:35:31 -0700 Subject: [PATCH] Removes try statement from container_definitions This commit prevents a race condition caused by the try statement in container_definitions. See: https://github.com/terraform-aws-modules/terraform-aws-ecs/issues/128 --- main.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.tf b/main.tf index 9d37a4d..329fd2e 100644 --- a/main.tf +++ b/main.tf @@ -101,7 +101,7 @@ module "service" { # Task definition create_task_definition = try(each.value.create_task_definition, true) task_definition_arn = lookup(each.value, "task_definition_arn", null) - container_definitions = try(each.value.container_definitions, {}) + container_definitions = each.value.container_definitions container_definition_defaults = try(each.value.container_definition_defaults, {}) cpu = try(each.value.cpu, 1024) ephemeral_storage = try(each.value.ephemeral_storage, {})