Skip to content

Commit

Permalink
chore: http health check endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
lsjostro committed Nov 3, 2024
1 parent 86ba768 commit abc3d54
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@ func NewServer(httpAddr string, certFile, keyFile string, services ...Service) *
mux.Handle(grpcreflect.NewHandlerV1(reflector))
mux.Handle(grpcreflect.NewHandlerV1Alpha(reflector))

// HTTP Health check endpoint
mux.HandleFunc("/healthz", func(w http.ResponseWriter, r *http.Request) {
w.WriteHeader(http.StatusOK)
})

// Create a new HTTP server
httpServer := &http.Server{
Addr: httpAddr,
Expand Down

0 comments on commit abc3d54

Please sign in to comment.