Skip to content

Commit 6321746

Browse files
authored
improvement: Tags passed into worker groups should also be excluded from Launch Template tag specification (#1095)
1 parent 4310197 commit 6321746

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

workers_launch_template.tf

+4-1
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,10 @@ resource "aws_launch_template" "workers_launch_template" {
456456
count.index,
457457
)}-eks_asg"
458458
},
459-
var.tags,
459+
{ for tag_key, tag_value in var.tags :
460+
tag_key => tag_value
461+
if tag_key != "Name" && ! contains([for tag in lookup(var.worker_groups_launch_template[count.index], "tags", local.workers_group_defaults["tags"]) : tag["key"]], tag_key)
462+
}
460463
)
461464
}
462465

0 commit comments

Comments
 (0)