all repos — homestead @ 6ccc55a35594ac618ab327d1c88205ee69f7250e

Code for my website

redirect OpenID configuration requests to dex

Alan Pearce
commit

6ccc55a35594ac618ab327d1c88205ee69f7250e

parent

322ae4b054c44425eba28c0d34e9b1ba69bc0cd2

1 file changed, 7 insertions(+), 0 deletions(-)

jump to
M internal/server/server.gointernal/server/server.go
@@ -188,6 +188,13 @@ log.Warn("error writing webfinger request", "error", err)
} } }) + const oidcPath = "/.well-known/openid-configuration" + mux.HandleFunc( + hostname+oidcPath, + func(w http.ResponseWriter, r *http.Request) { + u := config.OIDCHost.JoinPath(oidcPath) + http.Redirect(w, r, u.String(), 302) + }) mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { newURL := runtimeConfig.BaseURL.String() + r.URL.String()