From 67bdd18040e4e3dd2cfd5b942045a18e47dd3df9 Mon Sep 17 00:00:00 2001 From: SKairinos Date: Mon, 2 Dec 2024 10:44:56 +0000 Subject: [PATCH] fix: custom health check view --- codeforlife/urls/patterns.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/codeforlife/urls/patterns.py b/codeforlife/urls/patterns.py index f407ae6..2ab36c4 100644 --- a/codeforlife/urls/patterns.py +++ b/codeforlife/urls/patterns.py @@ -18,12 +18,14 @@ def get_urlpatterns( api_url_patterns: UrlPatterns, + health_check_view: t.Type[HealthCheckView] = HealthCheckView, include_user_urls: bool = True, ) -> UrlPatterns: """Generate standard url patterns for each service. Args: api_urls_path: The path to the api's urls. + health_check_view: The health check view to use. include_user_urls: Whether or not to include the CFL's user urls. Returns: @@ -77,7 +79,7 @@ def get_urlpatterns( health_check_path = path( "health-check/", - HealthCheckView.as_view(), + health_check_view.as_view(), name="health-check", )