diff --git a/oauthproxy.go b/oauthproxy.go index 21e5dfc74..2afa2ce11 100644 --- a/oauthproxy.go +++ b/oauthproxy.go @@ -152,7 +152,9 @@ func NewOAuthProxy(opts *Options, validator func(string) bool) *OAuthProxy { } redirectURL := opts.redirectURL - redirectURL.Path = fmt.Sprintf("%s/callback", opts.ProxyPrefix) + if redirectURL.String() == "" { + redirectURL.Path = fmt.Sprintf("%s/callback", opts.ProxyPrefix) + } log.Printf("OAuthProxy configured for %s Client ID: %s", opts.provider.Data().ProviderName, opts.ClientID) refresh := "disabled"