health check will never be able to get auth token so remove RootHandler wrapper

Signed-off-by: David Lawrence <david.lawrence@docker.com> (github: endophage)
This commit is contained in:
David Lawrence 2015-11-03 10:28:56 -08:00
parent 68992ddaf5
commit bc0c0d4ea1
1 changed files with 2 additions and 5 deletions

View File

@ -105,11 +105,8 @@ func RootHandler(ac auth.AccessController, ctx context.Context, trust signed.Cry
prometheus.InstrumentHandlerWithOpts(
prometheusOpts("DeleteTuf"),
hand(handlers.DeleteHandler, "push", "pull")))
r.Methods("GET").Path("/_notary_server/health").Handler(hand(
func(ctx context.Context, w http.ResponseWriter, r *http.Request) error {
health.StatusHandler(w, r)
return nil
}))
r.Methods("GET").Path("/_notary_server/health").HandlerFunc(health.StatusHandler)
r.Methods("GET").Path("/_notary_server/metrics").Handler(prometheus.Handler())
r.Methods("GET", "POST", "PUT", "HEAD", "DELETE").Path("/{other:.*}").Handler(hand(utils.NotFoundHandler))