mirror of
https://github.com/coollabsio/coolify.git
synced 2026-03-11 08:55:47 +00:00
feat(auth): enable forced oauth login with bypass
This commit is contained in:
parent
e12c4d29e0
commit
e5381814f1
2 changed files with 2 additions and 2 deletions
|
|
@ -61,7 +61,7 @@ class FortifyServiceProvider extends ServiceProvider
|
|||
$enabled_oauth_providers = OauthSetting::where('enabled', true)->get();
|
||||
$users = User::count();
|
||||
|
||||
if ($settings->oauth_auto_redirect && $enabled_oauth_providers->where('provider', $settings->oauth_auto_redirect)->isNotEmpty()) {
|
||||
if (!$request->has('skip_oauth') && $settings->oauth_auto_redirect && $enabled_oauth_providers->where('provider', $settings->oauth_auto_redirect)->isNotEmpty()) {
|
||||
return redirect()->route('auth.redirect', ['provider' => $settings->oauth_auto_redirect]);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
<div class="pb-4 ">Custom authentication (OAuth) configurations.</div>
|
||||
</div>
|
||||
<div class="mb-5">
|
||||
<x-forms.select label="Forced OAuth Login" id="oauth_auto_redirect" helper="If selected, users will be automatically redirected to this provider when visiting the login page.<br>To bypass this, use <code>/login?skip_oauth=true</code> (not implemented yet, but good practice to know).">
|
||||
<x-forms.select label="Forced OAuth Login" id="oauth_auto_redirect" helper="If selected, users will be automatically redirected to this provider when visiting the login page.<br>To bypass this, use <code>/login?skip_oauth=true</code>.">
|
||||
<option value="">None</option>
|
||||
@foreach ($oauth_settings_map as $oauth_setting)
|
||||
@if ($oauth_setting['enabled'])
|
||||
|
|
|
|||
Loading…
Reference in a new issue