ignore healtcheck requests in daphne logs

This commit is contained in:
Nick Sweeting 2024-09-10 00:05:13 -07:00
parent 1ce09b88d7
commit 04cb6bdfd6
No known key found for this signature in database

View file

@ -33,6 +33,8 @@ class ModifiedAccessLogGenerator(access.AccessLogGenerator):
# Ignore noisy requests to staticfiles / favicons / etc.
if 'GET /static/' in request:
return
if "GET /health/" in request:
return
if 'GET /admin/jsi18n/' in request:
return
if request.endswith("/favicon.ico") or request.endswith("/robots.txt") or request.endswith("/screenshot.png"):