about summary refs log tree commit diff stats
path: root/internal
diff options
context:
space:
mode:
authorAlan Pearce2024-05-22 19:01:43 +0200
committerAlan Pearce2024-05-23 05:16:24 +0200
commitcc40d876890ef8f886c79ed4b7a9700538870772 (patch)
treef2d07a697120bd4cb84359f60ee2991f822a4eb6 /internal
parent8469992f30544606151e200378afceb880843623 (diff)
downloadwebsite-cc40d876890ef8f886c79ed4b7a9700538870772.tar.lz
website-cc40d876890ef8f886c79ed4b7a9700538870772.tar.zst
website-cc40d876890ef8f886c79ed4b7a9700538870772.zip
don't log requests to /health
Diffstat (limited to 'internal')
-rw-r--r--internal/server/logging.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/internal/server/logging.go b/internal/server/logging.go
index d70d927..a574bcb 100644
--- a/internal/server/logging.go
+++ b/internal/server/logging.go
@@ -31,6 +31,9 @@ func wrapHandlerWithLogging(wrappedHandler http.Handler) http.Handler {
 		host := r.Host
 		lw := NewLoggingResponseWriter(w)
 		wrappedHandler.ServeHTTP(lw, r)
+		if r.URL.Path == "/health" {
+			return
+		}
 		statusCode := lw.statusCode
 		log.Info(
 			"http request",