From bb749b32b9441614b1af926f60848b9f5849aa62 Mon Sep 17 00:00:00 2001 From: Scooby Husky Date: Thu, 20 Aug 2026 20:33:22 -0500 Subject: [PATCH] Fix VPS Vault OIDC login: missing redirect_uri + missing DNS Two pre-existing gaps (not caused by this session's earlier work), surfaced when the user started testing the VPS's standby Vault (infrastructure/vps-standby/vault/) login via Authentik SSO: 1. VPS Vault's own auth/oidc/role/default allowed_redirect_uris only had vault.kube.huskypup.net (home) and localhost:8250 - never had vault.vps.huskypup.net registered, even though VPS's Vault shares the same Authentik OAuth2 provider/client_id as home's. Fixed on both sides: the shared blueprint (redirect_uris list) and VPS Vault's own role config directly (separate Vault instance/backend, needed its own write). 2. auth.kube.huskypup.net (Authentik itself) had NO public DNS record at all - it only ever resolved via UniFi's local DNS for home-LAN clients. Vault's OIDC backend runs server-side on the VPS and needs to fetch Authentik's discovery document directly - it silently returned an empty auth_url because it couldn't resolve the hostname at all ('missing auth_url' in Vault's UI, root cause only found by checking DNS resolution from inside the VPS's own vault pod). Added a public Cloudflare A record, same pattern as vault.kube.huskypup.net and pg-authentik.ha.huskypup.net earlier - user confirmed before adding, given it's Authentik itself. This likely also fixes OIDC for any other VPS-hosted app doing SSO against home's Authentik, not just Vault. Co-Authored-By: Claude Sonnet 5 --- infrastructure/authentik/vault-blueprint.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/infrastructure/authentik/vault-blueprint.yaml b/infrastructure/authentik/vault-blueprint.yaml index aeb6a7e..ddcbc43 100644 --- a/infrastructure/authentik/vault-blueprint.yaml +++ b/infrastructure/authentik/vault-blueprint.yaml @@ -45,6 +45,15 @@ spec: redirect_uris: - url: "https://vault.kube.huskypup.net/ui/vault/auth/oidc/oidc/callback" matching_mode: strict + # VPS's own standby Vault instance (infrastructure/vps-standby/vault/) + # shares this SAME Authentik provider/client_id - found missing + # 2026-08-21 while testing VPS vault login ("missing auth_url" - + # Vault silently returns no auth_url when the UI's computed + # redirect_uri isn't in allowed_redirect_uris; same fix needed on + # the VPS Vault's own auth/oidc/role/default, done separately since + # it's a fully independent Vault instance/backend). + - url: "https://vault.vps.huskypup.net/ui/vault/auth/oidc/oidc/callback" + matching_mode: strict - url: "http://localhost:8250/oidc/callback" matching_mode: strict property_mappings: