File tree Expand file tree Collapse file tree 1 file changed +2
-0
lines changed
Expand file tree Collapse file tree 1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -127,6 +127,7 @@ func main() {
127127 clientID = cfg .Oauth2ClientID
128128 clientSecret = cfg .Oauth2Secret
129129 externalUrl = cfg .ExternalURL
130+ redirectUrl = fmt .Sprintf ("%s/oauth2Callback" , externalUrl )
130131
131132 if cfg .Provider != "" {
132133 if ! SetProviderByName (cfg .Provider ) {
@@ -177,6 +178,7 @@ func main() {
177178 r .HandleFunc ("/history/commits" , runTemplate ("historyCommits.gohtml" )).Methods ("GET" ).MatcherFunc (RequiresAnAccount ())
178179
179180 r .HandleFunc ("/logout" , runHandlerChain (UserLogoutAction , runTemplate ("logoutPage.gohtml" ))).Methods ("GET" )
181+ r .HandleFunc ("/oauth2Callback" , runHandlerChain (Oauth2CallbackPage , redirectToHandler ("/" ))).Methods ("GET" )
180182
181183 r .HandleFunc ("/proxy/favicon" , FaviconProxyHandler ).Methods ("GET" )
182184
You can’t perform that action at this time.
0 commit comments