internal-apps (Fix): DNS cutover audit - harbor release, open-webui/media-admin logins, metrics shipping, https-only internal routes #1769

Merged
ginjiruu merged 6 commits from dns-cutover-audit into main 2026-11-21 01:17:34 +00:00
Owner

Audit of the 2026-11-20 internal DNS cutover (#1756 to #1768). The handoff called it done, with every Kustomization Ready. The 18 internal endpoints themselves are right: every Certificate is Ready, every ListenerSet and HTTPRoute is accepted, every name resolves on 10.30.100.53 to 10.10.6.40, and TLS verifies against the lab root. A lot around them broke. This PR fixes everything that can be fixed in git and is safe to merge on its own. The rest is listed below under "Needs you".

Merge order: lab/iac#179 first (kanidm must accept the media-admin callback), then this PR. lab/clusters#1770 is the second stage for Harbor pulls and has preconditions; see its description.

Fixed here

1. Harbor HelmRelease failing since 20:53Z (generic-templates/harbor)

#1759 set expose.type: none. That isn't a valid type for this chart: anything other than ingress/route renders the chart's nginx, and nginx requires expose.tls.auto.commonName, so every upgrade fails (harbor/harbor Ready=False). As a result Harbor's EXT_ENDPOINT never moved off https://harbor.animeteamspeak.moe, so Harbor SSO sends the retired callback, which kanidm no longer allows. The old chart route harbor/harbor-route was also left pointing at the deleted ListenerSet.

The stated reason for none ("the chart-built route would carry no internal DNS label") is wrong: chart 1.19.4 has expose.route.labels. Fix: type: route with the internal DNS label, parentRef ListenerSet harbor-internal (sectionName: https), host harbor.apps.caosh.int.animeteamspeak.moe, tls.certSource: none. The duplicate static HTTPRoute leaves routes-internal.yaml, which keeps the Certificate and ListenerSet. The chart route keeps its name harbor-route, so helm updates the stale live object in place.
Checked with helm template of 1.19.4 and these values: renders, no nginx objects, EXT_ENDPOINT: https://harbor.apps.caosh.int.animeteamspeak.moe, route labelled.

2. open-webui login gone (generic-templates/open-webui)

07425177 deleted the whole sso: block along with the public route, while ENABLE_PASSWORD_AUTH=false. Live /api/config shows "providers":{}, so nobody can log in. The block is restored from 9f65cd7a unchanged. OPENID_REDIRECT_URI is set to https://ai.apps.caosh.int.animeteamspeak.moe/oauth/oidc/callback, the exact callback kanidm's openwebui client allows (strict redirect).

3. media-admin answers 403 to everyone (generic-templates/media-stack)

The route, cert and DNS use media-admin.apps.caosh.int, but oauth-client.yaml, gateway-extension.yaml (redirectURI) and traffic-policy.yaml (CORS origin) used admin.media.apps.caosh.int, a name that doesn't exist. authz-bridge logs No App resolved for the Host. All of them now use media-admin.apps.caosh.int; two comments follow. lab/iac#179 fixes the kanidm side.

4. mini metrics and logs shipping dead since 22:04Z (clusters/mini/monitoring, victoriametrics, vault)

  • monitoring-vmagent and monitoring-vlagent remote-wrote to https://vm.animeteamspeak.moe/..., and every send got a connection reset. They now write in-cluster to http://vmauth-public-auth.vm.svc.cluster.local:8427/{vmagent,vlagent}/.... It's the same vmauth with the same bearer token and path routing, so no TLS or gateway hop is involved. No NetworkPolicy exists in vm or monitoring.
  • block-external-metrics-access and the VMAuth spec.httpRoute pointed at the deleted ListenerSet vmauth. The block route was Accepted=False, so https://vm.apps.caosh.int.animeteamspeak.moe/metrics returned 200 where it used to be blocked. The block route now attaches to vm-internal. The VMAuth httpRoute is removed because routes-internal.yaml already routes to vmauth-public-auth:8427, and the operator drops its dead vm/vmauth-public-auth route.
  • clusters/mini/vault/values.yaml still rendered the chart route on the deleted ListenerSet vault. Now httproute.enabled: false; routes-internal.yaml owns serving.

5. Internal routes served plain HTTP, vault included

Every routes-internal HTTPRoute bound both listeners (no sectionName), so http://<app>.apps.caosh.int/ served the app in cleartext: 200 for actual, agentvault, ai, harbor, inventory, workflows, and vault's API over HTTP. Each main route now attaches to sectionName: https. A sibling <name>-https-redirect route on sectionName: http answers 301 to https. Harbor's chart route gets the same treatment. automation is excluded: it is the argo-events webhook receiver, and a 301 drops POST bodies. That covers 17 files, including c1 httpbin.

6. portable: azuracast TLSRoute matched every name

#1759 deleted the TLSRoute's only hostname (cast) and left hostnames: empty. A TLSRoute without hostnames matches every listener on mini-passthrough, so it overlapped nats, s3.mini and exfil. The route is deleted (azuracast is decommissioned). portable's API is unreachable from here (connection reset at 70.26.10.82), so I couldn't check the live effect.

Checks

  • kustomize build passes for every touched folder.
  • kubectl --context mini apply --dry-run=server accepts all 18 mini/generic routes-internal files and the victoriametrics/monitoring builds. The only error is a GrafanaDashboard annotation-size limit, which comes from client-side apply; Flux applies server-side.
  • The pre-push gate passed (c1 + test; it doesn't render mini, see "Gaps").

After merge (what to watch)

  1. kubectl --context mini -n harbor get hr harbor: Ready, then kubectl -n harbor get httproute harbor-route -o yaml shows parent harbor-internal and the label. Harbor SSO login works at the internal name.
  2. https://ai.apps.caosh.int.animeteamspeak.moe/api/config shows the Animeteamspeak OIDC provider.
  3. https://media-admin.apps.caosh.int.animeteamspeak.moe/ redirects to kanidm (needs lab/iac#179 applied).
  4. vmagent/vlagent logs: no more connection reset. vm.apps.caosh.int/metrics answers 302.
  5. curl -sI http://vault.apps.caosh.int.animeteamspeak.moe/ returns 301 to https.

Needs you (live changes I did not make)

Your rule is to ask before live changes, so none of these were done:

  1. actual-budget SSO is broken. Its Deployment is a velero-restore orphan, not in git, and it still has ACTUAL_OPENID_SERVER_HOSTNAME=https://actual.animeteamspeak.moe. kanidm allows only the internal callback. Fix: kubectl -n actual-budget set env deploy/actual-server ACTUAL_OPENID_SERVER_HOSTNAME=https://actual.apps.caosh.int.animeteamspeak.moe (check the other ACTUAL_* URL vars with printenv first). Adopting the Deployment into clusters/mini/actual-budget/ is the durable fix.
  2. Orphans Flux will never prune (velero-restored, in no inventory):
    • HTTPRoutes with deleted parents: actual-budget/actual, automation/automation, homebox/homebox, paperless-ngx/paperless. (harbor/harbor-route, vault/vault and vm/vmauth-public-auth are cleaned up by this PR.)
    • Ingress karakeep/karakeep-web-ingress (keep.animeteamspeak.moe on cilium-ingress 10.10.6.0) still serves on the LAN. The router's web dst-nat goes to 10.10.6.14, so it should not be internet-reachable, but I didn't prove that.
    • Let's Encrypt certs that keep renewing for retired names: actual-budget/actual-animeteamspeak-moe-tls, automation/automation-tls, firefly/firefly-animeteamspeak-moe-tls, harbor/harbor-animeteamspeak-moe-tls, homebox/inventory-animeteamspeak-moe-tls, karakeep/keep-animeteamspeak-moe-tls, vault/vault-animeteamspeak-moe-tls.
      One command once you agree: kubectl --context mini delete ingress -n karakeep karakeep-web-ingress; kubectl --context mini delete httproute -n actual-budget actual; kubectl --context mini delete httproute -n automation automation; kubectl --context mini delete httproute -n homebox homebox; kubectl --context mini delete httproute -n paperless-ngx paperless plus the seven certificate deletes above.
  3. mail cluster (mx2) External Secrets store is NotReady since 20:58Z. clusters/mx2/external-secrets/vault-backend.yaml uses https://vault.animeteamspeak.moe, which is retired. Two ExternalSecrets stopped refreshing, including cert-manager's Cloudflare token. portable and remote have the same setting. Your local checkout deletes clusters/mx2/*, so I left it alone. Decide how off-mini clusters reach OpenBao now.
  4. glmocr (paperless OCR CronJob) broke with the cutover. Its live-only configmap (ArgoCD-tracked, ArgoCD dead) has BASE_URL: https://paper.animeteamspeak.moe. The 00:00Z run failed 7 times with ConnectionResetError. Option A: BASE_URL=https://paper.apps.caosh.int.animeteamspeak.moe plus the lab CA for python requests (REQUESTS_CA_BUNDLE pointing at a mounted lab-root-ca configmap; the coredns caosh.int forward already resolves the name in-cluster). Option B: the in-cluster paperless Service, with that host added to PAPERLESS_ALLOWED_HOSTS. Both are live edits on an orphan; adopting it into git is the durable fix.
  5. Not cutover-related, but you should know: 8 more HelmReleases on mini have been failing since 16:08-16:29Z, right after the #1753 renovate sweep merged at 16:02Z: reloader, frigate-home, grafana-operator, immich, kgateway, cilium (hubble-relay CrashLoopBackOff, 138 restarts), nats cluster, ollama. Most are timeout waiting for Deployment InProgress. Several pods (frigate, carwash-frigate, jellyfin, ollama) sit in ContainerStatusUnknown from 3 and 9 days ago. I didn't touch any of it.
  6. Harbor pulls: see lab/clusters#1770.

Corrections to the handoff

  • "Every Flux Kustomization and Terraform object Ready" hid HelmRelease harbor/harbor Ready=False, and checks on routes only, not app logins: open-webui, media-admin, actual, harbor SSO and vault UI were all broken.
  • "httpbin-cilium LS deleted": it is in git (clusters/mini/httpbin/resources) and live on cilium-default; httpbin.mini is just no longer in endpoints.yaml. It doesn't matter while the wildcard exists.
  • "harbor expose.type: none" and "chart route carries no DNS label" were both wrong (fix 1).
  • "media-admin 403 = expected" was the hostname mismatch (fix 3).

Gaps I did not fix

  • task gate renders only c1 and test, so nothing in mini's tree is gated. That's why every defect above got through. Worth a follow-up: a mini render plus a rule that every HTTPRoute/ListenerSet parentRef resolves.
  • Stale comments and docs naming retired hosts: docs/agents/secrets.md:67, docs/adr/0002*, generic-templates/azuracast/namespace.yaml:7, and the unreferenced generic-templates/victoriametrics/monitoring-stack-values.yaml and custom-resources/vmauth.yaml.
  • endpoints.yaml keeps expense (no backend anywhere), declares turn twice, and nats has no accepted ListenerSet. All of that predates today.
Audit of the 2026-11-20 internal DNS cutover (#1756 to #1768). The handoff called it done, with every Kustomization Ready. The 18 internal endpoints themselves are right: every Certificate is Ready, every ListenerSet and HTTPRoute is accepted, every name resolves on 10.30.100.53 to 10.10.6.40, and TLS verifies against the lab root. A lot around them broke. This PR fixes everything that can be fixed in git and is safe to merge on its own. The rest is listed below under "Needs you". **Merge order:** lab/iac#179 first (kanidm must accept the media-admin callback), then this PR. lab/clusters#1770 is the second stage for Harbor pulls and has preconditions; see its description. ## Fixed here ### 1. Harbor HelmRelease failing since 20:53Z (generic-templates/harbor) #1759 set `expose.type: none`. That isn't a valid type for this chart: anything other than `ingress`/`route` renders the chart's nginx, and nginx requires `expose.tls.auto.commonName`, so every upgrade fails (`harbor/harbor` Ready=False). As a result Harbor's `EXT_ENDPOINT` never moved off `https://harbor.animeteamspeak.moe`, so Harbor SSO sends the retired callback, which kanidm no longer allows. The old chart route `harbor/harbor-route` was also left pointing at the deleted ListenerSet. The stated reason for `none` ("the chart-built route would carry no internal DNS label") is wrong: chart 1.19.4 has `expose.route.labels`. Fix: `type: route` with the internal DNS label, parentRef `ListenerSet harbor-internal` (`sectionName: https`), host `harbor.apps.caosh.int.animeteamspeak.moe`, `tls.certSource: none`. The duplicate static HTTPRoute leaves `routes-internal.yaml`, which keeps the Certificate and ListenerSet. The chart route keeps its name `harbor-route`, so helm updates the stale live object in place. Checked with `helm template` of 1.19.4 and these values: renders, no nginx objects, `EXT_ENDPOINT: https://harbor.apps.caosh.int.animeteamspeak.moe`, route labelled. ### 2. open-webui login gone (generic-templates/open-webui) 07425177 deleted the whole `sso:` block along with the public route, while `ENABLE_PASSWORD_AUTH=false`. Live `/api/config` shows `"providers":{}`, so nobody can log in. The block is restored from 9f65cd7a unchanged. `OPENID_REDIRECT_URI` is set to `https://ai.apps.caosh.int.animeteamspeak.moe/oauth/oidc/callback`, the exact callback kanidm's `openwebui` client allows (strict redirect). ### 3. media-admin answers 403 to everyone (generic-templates/media-stack) The route, cert and DNS use `media-admin.apps.caosh.int`, but `oauth-client.yaml`, `gateway-extension.yaml` (redirectURI) and `traffic-policy.yaml` (CORS origin) used `admin.media.apps.caosh.int`, a name that doesn't exist. authz-bridge logs `No App resolved for the Host`. All of them now use `media-admin.apps.caosh.int`; two comments follow. lab/iac#179 fixes the kanidm side. ### 4. mini metrics and logs shipping dead since 22:04Z (clusters/mini/monitoring, victoriametrics, vault) - `monitoring-vmagent` and `monitoring-vlagent` remote-wrote to `https://vm.animeteamspeak.moe/...`, and every send got a connection reset. They now write in-cluster to `http://vmauth-public-auth.vm.svc.cluster.local:8427/{vmagent,vlagent}/...`. It's the same vmauth with the same bearer token and path routing, so no TLS or gateway hop is involved. No NetworkPolicy exists in `vm` or `monitoring`. - `block-external-metrics-access` and the VMAuth `spec.httpRoute` pointed at the deleted ListenerSet `vmauth`. The block route was `Accepted=False`, so `https://vm.apps.caosh.int.animeteamspeak.moe/metrics` returned 200 where it used to be blocked. The block route now attaches to `vm-internal`. The VMAuth `httpRoute` is removed because `routes-internal.yaml` already routes to `vmauth-public-auth:8427`, and the operator drops its dead `vm/vmauth-public-auth` route. - `clusters/mini/vault/values.yaml` still rendered the chart route on the deleted ListenerSet `vault`. Now `httproute.enabled: false`; `routes-internal.yaml` owns serving. ### 5. Internal routes served plain HTTP, vault included Every routes-internal HTTPRoute bound both listeners (no `sectionName`), so `http://<app>.apps.caosh.int/` served the app in cleartext: 200 for actual, agentvault, ai, harbor, inventory, workflows, and vault's API over HTTP. Each main route now attaches to `sectionName: https`. A sibling `<name>-https-redirect` route on `sectionName: http` answers 301 to https. Harbor's chart route gets the same treatment. **automation is excluded:** it is the argo-events webhook receiver, and a 301 drops POST bodies. That covers 17 files, including c1 httpbin. ### 6. portable: azuracast TLSRoute matched every name #1759 deleted the TLSRoute's only hostname (`cast`) and left `hostnames:` empty. A TLSRoute without hostnames matches every listener on `mini-passthrough`, so it overlapped nats, s3.mini and exfil. The route is deleted (azuracast is decommissioned). portable's API is unreachable from here (connection reset at 70.26.10.82), so I couldn't check the live effect. ## Checks - `kustomize build` passes for every touched folder. - `kubectl --context mini apply --dry-run=server` accepts all 18 mini/generic routes-internal files and the victoriametrics/monitoring builds. The only error is a GrafanaDashboard annotation-size limit, which comes from client-side apply; Flux applies server-side. - The pre-push gate passed (c1 + test; it doesn't render mini, see "Gaps"). ## After merge (what to watch) 1. `kubectl --context mini -n harbor get hr harbor`: Ready, then `kubectl -n harbor get httproute harbor-route -o yaml` shows parent `harbor-internal` and the label. Harbor SSO login works at the internal name. 2. `https://ai.apps.caosh.int.animeteamspeak.moe/api/config` shows the Animeteamspeak OIDC provider. 3. `https://media-admin.apps.caosh.int.animeteamspeak.moe/` redirects to kanidm (needs lab/iac#179 applied). 4. vmagent/vlagent logs: no more `connection reset`. `vm.apps.caosh.int/metrics` answers 302. 5. `curl -sI http://vault.apps.caosh.int.animeteamspeak.moe/` returns 301 to https. ## Needs you (live changes I did not make) Your rule is to ask before live changes, so none of these were done: 1. **actual-budget SSO is broken.** Its Deployment is a velero-restore orphan, not in git, and it still has `ACTUAL_OPENID_SERVER_HOSTNAME=https://actual.animeteamspeak.moe`. kanidm allows only the internal callback. Fix: `kubectl -n actual-budget set env deploy/actual-server ACTUAL_OPENID_SERVER_HOSTNAME=https://actual.apps.caosh.int.animeteamspeak.moe` (check the other `ACTUAL_*` URL vars with `printenv` first). Adopting the Deployment into `clusters/mini/actual-budget/` is the durable fix. 2. **Orphans Flux will never prune** (velero-restored, in no inventory): - HTTPRoutes with deleted parents: `actual-budget/actual`, `automation/automation`, `homebox/homebox`, `paperless-ngx/paperless`. (`harbor/harbor-route`, `vault/vault` and `vm/vmauth-public-auth` are cleaned up by this PR.) - Ingress `karakeep/karakeep-web-ingress` (keep.animeteamspeak.moe on cilium-ingress 10.10.6.0) **still serves on the LAN**. The router's web dst-nat goes to 10.10.6.14, so it should not be internet-reachable, but I didn't prove that. - Let's Encrypt certs that keep renewing for retired names: `actual-budget/actual-animeteamspeak-moe-tls`, `automation/automation-tls`, `firefly/firefly-animeteamspeak-moe-tls`, `harbor/harbor-animeteamspeak-moe-tls`, `homebox/inventory-animeteamspeak-moe-tls`, `karakeep/keep-animeteamspeak-moe-tls`, `vault/vault-animeteamspeak-moe-tls`. One command once you agree: `kubectl --context mini delete ingress -n karakeep karakeep-web-ingress; kubectl --context mini delete httproute -n actual-budget actual; kubectl --context mini delete httproute -n automation automation; kubectl --context mini delete httproute -n homebox homebox; kubectl --context mini delete httproute -n paperless-ngx paperless` plus the seven `certificate` deletes above. 3. **mail cluster (mx2) External Secrets store is NotReady since 20:58Z.** `clusters/mx2/external-secrets/vault-backend.yaml` uses `https://vault.animeteamspeak.moe`, which is retired. Two ExternalSecrets stopped refreshing, including cert-manager's Cloudflare token. portable and remote have the same setting. Your local checkout deletes `clusters/mx2/*`, so I left it alone. Decide how off-mini clusters reach OpenBao now. 4. **glmocr (paperless OCR CronJob) broke with the cutover.** Its live-only configmap (ArgoCD-tracked, ArgoCD dead) has `BASE_URL: https://paper.animeteamspeak.moe`. The 00:00Z run failed 7 times with `ConnectionResetError`. Option A: `BASE_URL=https://paper.apps.caosh.int.animeteamspeak.moe` plus the lab CA for python requests (`REQUESTS_CA_BUNDLE` pointing at a mounted `lab-root-ca` configmap; the coredns caosh.int forward already resolves the name in-cluster). Option B: the in-cluster paperless Service, with that host added to `PAPERLESS_ALLOWED_HOSTS`. Both are live edits on an orphan; adopting it into git is the durable fix. 5. **Not cutover-related, but you should know:** 8 more HelmReleases on mini have been failing since 16:08-16:29Z, right after the #1753 renovate sweep merged at 16:02Z: reloader, frigate-home, grafana-operator, immich, kgateway, cilium (hubble-relay CrashLoopBackOff, 138 restarts), nats cluster, ollama. Most are `timeout waiting for Deployment InProgress`. Several pods (frigate, carwash-frigate, jellyfin, ollama) sit in ContainerStatusUnknown from 3 and 9 days ago. I didn't touch any of it. 6. **Harbor pulls**: see lab/clusters#1770. ## Corrections to the handoff - "Every Flux Kustomization and Terraform object Ready" hid HelmRelease `harbor/harbor` Ready=False, and checks on routes only, not app logins: open-webui, media-admin, actual, harbor SSO and vault UI were all broken. - "httpbin-cilium LS deleted": it is in git (`clusters/mini/httpbin/resources`) and live on cilium-default; `httpbin.mini` is just no longer in `endpoints.yaml`. It doesn't matter while the wildcard exists. - "harbor `expose.type: none`" and "chart route carries no DNS label" were both wrong (fix 1). - "media-admin 403 = expected" was the hostname mismatch (fix 3). ## Gaps I did not fix - `task gate` renders only c1 and test, so nothing in mini's tree is gated. That's why every defect above got through. Worth a follow-up: a mini render plus a rule that every HTTPRoute/ListenerSet parentRef resolves. - Stale comments and docs naming retired hosts: `docs/agents/secrets.md:67`, `docs/adr/0002*`, `generic-templates/azuracast/namespace.yaml:7`, and the unreferenced `generic-templates/victoriametrics/monitoring-stack-values.yaml` and `custom-resources/vmauth.yaml`. - `endpoints.yaml` keeps `expense` (no backend anywhere), declares `turn` twice, and `nats` has no accepted ListenerSet. All of that predates today.
Sign in to join this conversation.
No description provided.