Skip to content

Commit

Permalink
Add finops tags to karpenter provisioned nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
mcgin314 committed Sep 13, 2024
1 parent c19fdab commit 7ffc8b8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ec2_node_class.yaml.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,6 @@ spec:

# Optional, configures detailed monitoring for the instance
detailedMonitoring: true

# Add finops tags to karpenter provisioned nodes
tags: ${tags}
1 change: 1 addition & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,7 @@ resource "kubectl_manifest" "karpenter_ec2_node_class" {
]
yaml_body = templatefile("${path.module}/ec2_node_class.yaml.tpl", {
cluster_name = var.cluster_name
tags = jsonencode(var.tags)
amd_ami_family = "Bottlerocket"
amd_ami_alias = "bottlerocket"
})
Expand Down

0 comments on commit 7ffc8b8

Please sign in to comment.