mirror of
https://github.com/adnanh/webhook.git
synced 2026-07-27 01:29:16 +08:00
add handler for the route to be used as a healtcheck endpoint, fixes #233
This commit is contained in:
@@ -185,6 +185,10 @@ func main() {
|
||||
hooksURL = "/" + *hooksURLPrefix + "/{id}"
|
||||
}
|
||||
|
||||
router.HandleFunc("/", func(w http.ResponseWriter, req *http.Request) {
|
||||
fmt.Fprintf(w, "OK")
|
||||
})
|
||||
|
||||
router.HandleFunc(hooksURL, hookHandler)
|
||||
|
||||
n.UseHandler(router)
|
||||
|
||||
Reference in New Issue
Block a user