Revert "root: handle liveness probe in router (also keep internal one)"
This reverts commit dd7cb45733
.
This commit is contained in:
parent
dd7cb45733
commit
57e86582d1
|
@ -39,6 +39,9 @@ func (ws *WebServer) configureProxy() {
|
||||||
}
|
}
|
||||||
ws.proxyErrorHandler(rw, r, fmt.Errorf("proxy not running"))
|
ws.proxyErrorHandler(rw, r, fmt.Errorf("proxy not running"))
|
||||||
})
|
})
|
||||||
|
ws.m.Path("/-/health/live/").HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
|
||||||
|
rw.WriteHeader(204)
|
||||||
|
})
|
||||||
ws.m.PathPrefix("/").HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
|
ws.m.PathPrefix("/").HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
|
||||||
if !ws.p.IsRunning() {
|
if !ws.p.IsRunning() {
|
||||||
ws.proxyErrorHandler(rw, r, fmt.Errorf("authentik core not running yet"))
|
ws.proxyErrorHandler(rw, r, fmt.Errorf("authentik core not running yet"))
|
||||||
|
|
Reference in a new issue