Skip to content

update tags specifications, move tags.yml gen to root.hcl #50

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ locals {
"172.16.0.0/12",
"192.168.0.0/16"])
filtered_endpoint_public_access_cidrs = distinct([for cidr in var.census_private_cidr : cidr if ! contains(local.disallowed_public_endpoint_cidrs, lower(trimspace(cidr)))])
tags = merge(
module.tags.tags,
{ "kubernetes.io/cluster/${var.cluster_name}" = "owned" },
{ "boc:created-by" = "launch-template" }
)
}

resource "terraform_data" "subnet_validation" {
Expand Down Expand Up @@ -89,13 +94,8 @@ module "cluster" {
labels = {
"karpenter.sh/controller" = "true"
}
tag_specifications = ["instance", "volume"]
tags = merge(
module.tags.tags,
{
"kubernetes.io/cluster/${var.cluster_name}" = "owned"
}
)
tag_specifications = ["instance", "volume", "network-interface"]
tags = local.tags
}
}
}
Expand Down
3 changes: 2 additions & 1 deletion tags.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
module "tags" {
# tflint-ignore: terraform_module_pinned_source
source = "git@github.e.it.census.gov:terraform-modules/boc-nts//tags"
source = "git@github.e.it.census.gov:terraform-modules/boc-nts//tags"
# tags.yml will be generated via terragrunt in root.hcl
filename = format("%v/%v", path.root, "tags.yml")

}
5 changes: 0 additions & 5 deletions tags.yml

This file was deleted.

Loading