mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-02 01:12:16 +00:00
feat(auth): let admins keep the login page on OIDC-only instances (#2925)
A new app setting oidc_auto_redirect (default on) is part of the admin form and the public app config. Off, an instance without password login no longer sends visitors straight to the IdP: the login page shows its SSO button, also while the cached config is read. Admin toggle on desktop and phone.
This commit is contained in:
@@ -100,6 +100,7 @@ describe('useAdmin', () => {
|
||||
password_registration: false,
|
||||
oidc_login: false,
|
||||
oidc_registration: false,
|
||||
oidc_auto_redirect: false,
|
||||
env_override_oidc_only: true,
|
||||
oidc_configured: true,
|
||||
require_mfa: 1,
|
||||
@@ -116,6 +117,7 @@ describe('useAdmin', () => {
|
||||
expect(result.current.passwordRegistration).toBe(false);
|
||||
expect(result.current.oidcLogin).toBe(false);
|
||||
expect(result.current.oidcRegistration).toBe(false);
|
||||
expect(result.current.oidcAutoRedirect).toBe(false);
|
||||
expect(result.current.envOverrideOidcOnly).toBe(true);
|
||||
expect(result.current.oidcConfigured).toBe(true);
|
||||
expect(result.current.requireMfa).toBe(true);
|
||||
|
||||
Reference in New Issue
Block a user