ISSUE-4244 comply with --health-check-path (#4619)
This commit is contained in:
parent
d5d2b4037c
commit
203a3ed455
2 changed files with 89 additions and 75 deletions
|
|
@ -135,7 +135,7 @@ func main() {
|
|||
go registerProfiler()
|
||||
}
|
||||
|
||||
registerHealthz(ngx, mux)
|
||||
registerHealthz(nginx.HealthPath, ngx, mux)
|
||||
registerMetrics(reg, mux)
|
||||
registerHandlers(mux)
|
||||
|
||||
|
|
@ -247,9 +247,10 @@ func registerHandlers(mux *http.ServeMux) {
|
|||
})
|
||||
}
|
||||
|
||||
func registerHealthz(ic *controller.NGINXController, mux *http.ServeMux) {
|
||||
func registerHealthz(healthPath string, ic *controller.NGINXController, mux *http.ServeMux) {
|
||||
// expose health check endpoint (/healthz)
|
||||
healthz.InstallHandler(mux,
|
||||
healthz.InstallPathHandler(mux,
|
||||
healthPath,
|
||||
healthz.PingHealthz,
|
||||
ic,
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue