Pass the req context when pinging the DB

This commit is contained in:
Juan Font Alonso 2022-09-04 11:43:09 +02:00
parent 4527801d48
commit f23e9dc235
2 changed files with 3 additions and 3 deletions

2
api.go
View file

@ -52,7 +52,7 @@ func (h *Headscale) HealthHandler(
}
}
if err := h.pingDB(); err != nil {
if err := h.pingDB(req.Context()); err != nil {
respond(err)
return