mirror of
https://github.com/steveiliop56/tinyauth.git
synced 2025-10-28 12:45:47 +00:00
feat: add support for auto redirecting to oauth providers
This commit is contained in:
@@ -51,6 +51,7 @@ type AppContext struct {
|
||||
GenericName string `json:"genericName"`
|
||||
Domain string `json:"domain"`
|
||||
ForgotPasswordMessage string `json:"forgotPasswordMessage"`
|
||||
OAuthAutoRedirect string `json:"oauthAutoRedirect"`
|
||||
}
|
||||
|
||||
// Totp request is the request for the totp endpoint
|
||||
|
||||
@@ -26,6 +26,7 @@ type Config struct {
|
||||
GenericName string `mapstructure:"generic-name"`
|
||||
DisableContinue bool `mapstructure:"disable-continue"`
|
||||
OAuthWhitelist string `mapstructure:"oauth-whitelist"`
|
||||
OAuthAutoRedirect string `mapstructure:"oauth-auto-redirect" validate:"oneof=none github google generic"`
|
||||
SessionExpiry int `mapstructure:"session-expiry"`
|
||||
LogLevel int8 `mapstructure:"log-level" validate:"min=-1,max=5"`
|
||||
Title string `mapstructure:"app-title"`
|
||||
@@ -44,6 +45,7 @@ type HandlersConfig struct {
|
||||
GenericName string
|
||||
Title string
|
||||
ForgotPasswordMessage string
|
||||
OAuthAutoRedirect string
|
||||
}
|
||||
|
||||
// OAuthConfig is the configuration for the providers
|
||||
|
||||
Reference in New Issue
Block a user