From 40662b2b743a5d446b9bcb721586bfbbc4ff01be Mon Sep 17 00:00:00 2001 From: juvdiaz Date: Tue, 26 May 2026 23:05:21 -0600 Subject: [PATCH] Add NodeLocal DNSCache platform component --- README.md | 10 + bootstrap/platform/main.tf | 338 ++++++++++++++++++++++++++++++++ bootstrap/platform/variables.tf | 20 ++ 3 files changed, 368 insertions(+) diff --git a/README.md b/README.md index da21349..1f2649a 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,7 @@ accidentally modify the cluster. 3. `bootstrap/platform` - installs a minimal Calico deployment through the Tigera operator + - installs NodeLocal DNSCache for node-local DNS query caching - installs OpenEBS - creates `openebs-hostpath-retain` - installs Argo CD @@ -230,6 +231,15 @@ settings without blocking existing pods during the first rollout. After reports are clean, individual policies can be promoted to `Enforce` in `bootstrap/platform/main.tf`. +## DNS Cache + +`bootstrap/platform` installs NodeLocal DNSCache in `kube-system` with +`registry.k8s.io/dns/k8s-dns-node-cache`. The default listens on +`169.254.20.10` and the kube-dns service IP `10.96.0.10`, which keeps the +rollout compatible with the current kube-proxy iptables path without rewriting +kubelet DNS settings across the nodes. Override `nodelocal_dns` if the service +CIDR or upstream DNS servers change. + ## Secrets Use SOPS with age for secrets that need to live in Git. Start from diff --git a/bootstrap/platform/main.tf b/bootstrap/platform/main.tf index c76b411..168246a 100644 --- a/bootstrap/platform/main.tf +++ b/bootstrap/platform/main.tf @@ -26,6 +26,57 @@ provider "helm" { } } +locals { + nodelocal_dns_corefile = <