diff --git a/robot/web/web.go b/robot/web/web.go index 3660835cdda..062d66e7d6e 100644 --- a/robot/web/web.go +++ b/robot/web/web.go @@ -688,7 +688,11 @@ func (svc *webService) initHTTPServer(listenerTCPAddr *net.TCPAddr, options webo // Initialize multiplexer between http handlers. func (svc *webService) initMux(options weboptions.Options) *goji.Mux { mux := goji.NewMux() - mux.Handle(pat.New("/"), http.NotFoundHandler()) + // Note: used by viam-agent for health checks + mux.HandleFunc(pat.New("/"), func(w http.ResponseWriter, _ *http.Request) { + w.WriteHeader(200) + w.Write([]byte("healthy")) + }) if options.Pprof { mux.HandleFunc(pat.New("/debug/pprof/"), pprof.Index)