fix(fw,web-arm): make the Warpgate and OneCLI SSO logins work against Authelia #548
No reviewers
Labels
No labels
bug
enhancement
in-progress
needs-info
needs-triage
p0
ready-for-agent
ready-for-human
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Cloonar/nixos!548
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "lab/20261026-1220"
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?
Refs #452 (the Keycloak-to-Authelia switch; Keycloak retirement stays a follow-up).
Both SSO logins were still failing against Authelia, for different reasons.
Warpgate: the Authelia config never reached disk
The live process on fw has been running since Oct 7 and its SSO return still carries
iss=https://sso.cloonar.com/realms/cloonar. Thelib.mkForceExecStart added for--enable-admin-token(cb254570) replaced upstream's start script, and that script is what copies the rendered config into/var/lib/warpgate/config.yamlon every start. Consequences:settingschange does not restart it on switch (verified: no restart of warpgate.service in any bento activation since Oct 10).Fix: render the settings with
pkgs.formats.yamland install that file inExecStartPrebefore the existing secret injection. The store reference also makes settings changes restart the unit again. On 26.11 upstream does its own copy inExecStartPre; ours then runs after it and is a harmless repeat.OneCLI: Auth.js sends no
state, Authelia rejects the requestAuthelia's log for every attempt:
OneCLI reports that as
OAuthCallbackError. Auth.js v5 defaults tochecks: ["pkce"], so the authorization URL carries nostate; Keycloak tolerated that, Authelia does not. Patch 01 now setschecks: ["pkce", "state"].Deploy steps after merge
hosts/web-arm/modules/onecli/update.shon a machine with root on web-arm. The suffix is bumped tocl7; the script rebuilds, pushes and repins the digest indefault.nix. The pin in this PR is stillcl6, so the OneCLI half only takes effect once that repin is committed. The lab could not do this: GitHub is blocked by the credential gateway and only the read-only Diag channel reaches web-arm.Side observation, not touched here: every Warpgate SSO login logs
SSO role mapping references non-existent role "warpgate:admin", skipping.Verification: the patch's hunk counts were re-checked arithmetically; pre-commit dry-build ran on commit.
🤖 Generated with Claude Code