internal-apps (Add): internal gateway, OpenBao issuer, internal external-dns #1750
No reviewers
Labels
No labels
epic
fleet:hub
fleet:identity
fleet:ingress
fleet:offload
fleet:sveltos
needs-triage
ready-for-agent
ready-for-human
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
lab/clusters!1750
Loading…
Reference in a new issue
No description provided.
Delete branch "internal-apps-dns"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Infrastructure for internal app names on mini:
<app>.apps.caosh.int.animeteamspeak.moe(machine-configs ADR-0005 amendment), served only on a gateway the internet cannot reach, with certs from OpenBao. No app moves in this PR. Pairs with lab/iac#167.Why a second gateway
gateway/cilium-default(10.10.6.14) is the WAN port-forward target for 80/443 (iacmodules/siteport_forwards.web). Every route on it is reachable from the internet with aHost:header, whatever public DNS says. Internal apps move togateway/cilium-internal(10.10.6.40), which is never forwarded. The routers let trusted clients reach it, plus the servers zone (c1) on 80/443 (lab/iac#167); mgmt, iot and guest get nothing.mini
gateway/internal-gateway.yaml: Gatewaycilium-internal,spec.addresses: 10.10.6.40, HTTP/HTTPS listeners, ListenerSets from all namespaces (same shape ascilium-default).gateway/gateway.yaml:cilium-defaultpinned to10.10.6.14. Today that address is dynamic and only stable by luck, while the WAN forward depends on it.internal-apps/issuer: ClusterIssueropenbao-apps(cert-manager Vault issuer) onpki-apps-caosh/sign/cert-manager. It logs in atauth/kubernetes-miniwith a token forcert-manager/openbao-apps-issuer, with audience = the API server issuer, matching the iac role. Role/RoleBinding let the cert-manager controller request that token.caBundleis the lab root, fingerprint-checked against mini'sflux-system/lab-root-ca.internal-apps/external-dns: external-dns 0.23, pdns provider againsthttp://10.30.100.12:8081.crd,gateway-httproute,gateway-tlsroutelabelFilter: dns.animeteamspeak.moe/internal=true--gateway-name=cilium-internal: only routes on the internal gateway, so records are A10.10.6.40mini, domain filterapps.caosh.int.animeteamspeak.moe10.30.100.12:8081onlyeso/openbao-infra.yaml: ClusterSecretStore on theinframount for the PowerDNS API key (lab/iac#167 grants exactly that path).c1
dns/auth/primary.yaml: Servicepdns-api, LoadBalancer pinned10.30.100.12, port 8081 to the primary.externalTrafficPolicy: Localkeeps mini's pod address as the source.10.44.0.0/16(mini's pod pool) on 8081. mini routes pods without masquerade inside 10/8.How an app opts in (the per-app batches)
parentRefchanges togateway/cilium-internal, with hostname<app>.apps.caosh.int.animeteamspeak.moe.openbao-appsfor that name.dns.animeteamspeak.moe/internal: "true", and its public entry leaves the central list.vault-backend, containerd's harbor mirror, vm agents, velero and the nix cache ons3.mini).Checks
kustomize buildon every new and changed directory; the pre-push gate passed (c1 165 objects).helm templaterenders the intended flags, including--gateway-name=cilium-internaland--label-filter=dns.animeteamspeak.moe/internal=true.pki-apps-caoshwas proven on the harness OpenBao (lab/iac#167): a leaf forgrafana.apps.caosh.int…verifies to the lab root, and a name outside the zone is refused.openbao-appsReady; a throwaway Certificate issues; a test route publishes an A record visible through the recursor.Also in this PR's orbit
#1749 now restricts the public external-dns to
--gateway-name=cilium-default, so a route on the internal gateway can never publish a private address publicly.Merge order
lab/iac#167 first (the CA, the login role, the secret grant). Otherwise ClusterIssuer
openbao-appsstays not-Ready and the internal external-dns cannot read its key; both retry, nothing breaks.