We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8104239 commit fa6cd0bCopy full SHA for fa6cd0b
apisprout.go
@@ -438,6 +438,12 @@ func server(cmd *cobra.Command, args []string) {
438
})
439
}
440
441
+ // Add a health check route which returns 200
442
+ http.HandleFunc("/__health", func(w http.ResponseWriter, r *http.Request) {
443
+ w.WriteHeader(200)
444
+ log.Printf("Health check")
445
+ })
446
+
447
// Register our custom HTTP handler that will use the router to find
448
// the appropriate OpenAPI operation and try to return an example.
449
http.HandleFunc("/", func(w http.ResponseWriter, req *http.Request) {
0 commit comments