docs(authentik,openwebui): the roles claim mints the OpenWebUI role; jason joins the census #144

Merged
dank merged 2 commits from docs/authentik-jason-provision into main 2026-11-04 12:57:07 -08:00
Owner

Provision jason and correct the OpenWebUI first-login role law

Provisioned the human account Frank asked for (Authentik username jason,
jason@franksdank.cloud, template groups). The credential itself never enters
the repo — it travelled in stdin only and is not written to any file, page, or
commit here.

Live verification (why the docs changed)

  1. ak shell create → pk 24, authenticate() truthy for the password and
    None for a wrong one, groups Non-Admin Users + jellyfin_users +
    openwebui_users (the 11-precedent human template), app_entitlements for
    the open-webui application identical to the precedent user.
  2. The Open WebUI roles mapping is a ScopeMapping attached to the
    Open WebUI OAuth2 provider's property_mappings, and the login request
    asks scope=openid email profile roles — so the mapping rides the token.
  3. Drove the real first SSO login in a clean managed browser:
    ai.franksdank.cloud → "Continue with authentik" (the login view shows no
    password form — the SSO-only posture holds) → identification → password →
    landed signed in as Jason.
  4. The minted row is role='user' with zero manual steps. One chat turn
    answered; "Read Aloud" issued exactly one POST /api/v1/audio/speech → 200
    with no /wasm/ort-wasm-* fetch, and frank-tts logged
    speech voice=wilwheaton. A virgin account therefore lands on the server TTS
    path by default.

Docs

  • Dankclaw/OpenWebUI.md — the First login mints role pending bullet is
    destroyed and replaced: with ENABLE_OAUTH_ROLE_MANAGEMENT=true and the
    roles claim present, the claim decides the role;
    ui.default_user_role=pending is only the fallback for an account the claim
    does not describe, and 0.12.5's get_user_role refuses the login with 403
    when role management is on and no roles claim is readable. So "SSO worked but
    I cannot chat" means a missing openwebui_users group/entitlement — not a row
    waiting for the UPDATE "user" SET role='user' incantation, which stays
    documented as the repair for a genuinely stuck row.
  • Infrastructure/Authentik.md — human-user template census gains jason,
    pk 24 (created 2026-11-04); pk table re-read against authentik_core_user.

Not in this PR

scripts/, quadlets, Caddy: untouched. No deploy — documentation-only change
per the planner. The harness skill for this procedure
(authentik-provision-fleet-user) was corrected out-of-band: it still told
agents to append a dated entry to serverAppConfigs-docs/log.md, which was
destroyed 2026-10-19.


cwd: /home/blank/.omp/wt/wt-20261104-104444-6d1fc1f · session: 01a1a7eb-c584-72d3-9d7e-c02d981cd662

# Provision `jason` and correct the OpenWebUI first-login role law Provisioned the human account Frank asked for (Authentik username `jason`, `jason@franksdank.cloud`, template groups). The credential itself never enters the repo — it travelled in stdin only and is not written to any file, page, or commit here. ## Live verification (why the docs changed) 1. `ak shell` create → pk 24, `authenticate()` truthy for the password and `None` for a wrong one, groups `Non-Admin Users` + `jellyfin_users` + `openwebui_users` (the 11-precedent human template), `app_entitlements` for the `open-webui` application identical to the precedent user. 2. The `Open WebUI roles` mapping is a `ScopeMapping` attached to the `Open WebUI` OAuth2 provider's `property_mappings`, and the login request asks `scope=openid email profile roles` — so the mapping rides the token. 3. Drove the **real first SSO login** in a clean managed browser: `ai.franksdank.cloud` → "Continue with authentik" (the login view shows no password form — the SSO-only posture holds) → identification → password → landed signed in as Jason. 4. The minted row is **`role='user'` with zero manual steps**. One chat turn answered; "Read Aloud" issued exactly one `POST /api/v1/audio/speech` → 200 with **no** `/wasm/ort-wasm-*` fetch, and `frank-tts` logged `speech voice=wilwheaton`. A virgin account therefore lands on the server TTS path by default. ## Docs - `Dankclaw/OpenWebUI.md` — the *First login mints role `pending`* bullet is destroyed and replaced: with `ENABLE_OAUTH_ROLE_MANAGEMENT=true` and the `roles` claim present, **the claim decides the role**; `ui.default_user_role=pending` is only the fallback for an account the claim does not describe, and 0.12.5's `get_user_role` refuses the login with **403** when role management is on and no roles claim is readable. So "SSO worked but I cannot chat" means a missing `openwebui_users` group/entitlement — not a row waiting for the `UPDATE "user" SET role='user'` incantation, which stays documented as the repair for a genuinely stuck row. - `Infrastructure/Authentik.md` — human-user template census gains `jason`, pk 24 (created 2026-11-04); pk table re-read against `authentik_core_user`. ## Not in this PR `scripts/`, quadlets, Caddy: untouched. No deploy — documentation-only change per the planner. The harness skill for this procedure (`authentik-provision-fleet-user`) was corrected out-of-band: it still told agents to append a dated entry to `serverAppConfigs-docs/log.md`, which was destroyed 2026-10-19. --- cwd: /home/blank/.omp/wt/wt-20261104-104444-6d1fc1f · session: 01a1a7eb-c584-72d3-9d7e-c02d981cd662
dank added 2 commits 2026-11-04 12:45:18 -08:00
Provisioned jason (pk 24, human-user template) and drove his first SSO
login in a clean browser: the row appeared as role='user' with chat and
wilwheaton TTS working, no manual step. The pending-then-flip law is
therefore wrong for a claim-carrying account - ENABLE_OAUTH_ROLE_MANAGEMENT
+ the roles scope decide it, and 0.12.5 refuses a claim-less login with 403
instead of falling back to ui.default_user_role. Census gains jason.
dank merged commit cae283047f into main 2026-11-04 12:57:07 -08:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: dank/serverAppConfigs#144