From 3789bb9687ceab674860959fa3ba3d68ebc6a5e6 Mon Sep 17 00:00:00 2001 From: Harry Herbig Date: Tue, 23 Jul 2024 11:45:37 +0200 Subject: [PATCH] bugfix condition for cloudwatch logs group creation --- cloudwatch_logs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cloudwatch_logs.tf b/cloudwatch_logs.tf index d668a36..8d70bb6 100644 --- a/cloudwatch_logs.tf +++ b/cloudwatch_logs.tf @@ -1,5 +1,5 @@ resource "aws_cloudwatch_log_group" "containers" { - count = var.cloudwatch_logs.enabled && var.cloudwatch_logs.name != "" ? 1 : 0 + count = var.cloudwatch_logs.enabled && var.cloudwatch_logs.name == "" ? 1 : 0 name = var.cloudwatch_logs.name == "" ? "/aws/ecs/${var.service_name}" : var.cloudwatch_logs.name retention_in_days = var.cloudwatch_logs.retention_in_days