Skip to content

Commit

Permalink
irsa_tag_values coalescelist improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
tongueroo committed May 17, 2023
1 parent 3aaaf90 commit e35fcba
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion modules/karpenter/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ resource "aws_iam_role" "irsa" {
}

locals {
irsa_tag_values = var.irsa_tag_values == null ? [var.cluster_name] : var.irsa_tag_values
irsa_tag_values = coalescelist([var.cluster_name], var.irsa_tag_values)
}

data "aws_iam_policy_document" "irsa" {
Expand Down
2 changes: 1 addition & 1 deletion modules/karpenter/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ variable "irsa_tag_key" {
}

variable "irsa_tag_values" {
description = "Tag value (`{key = value}`) applied to resources launched by Karpenter through the Karpenter provisioner. Defaults to cluster name when not set."
description = "Tag values (`{key = value}`) applied to resources launched by Karpenter through the Karpenter provisioner. Defaults to cluster name when not set."
type = list(string)
default = null
}
Expand Down

0 comments on commit e35fcba

Please sign in to comment.