Skip to content
Snippets Groups Projects
Verified Commit 6362bfa1 authored by Tom Teichler's avatar Tom Teichler :beers:
Browse files

Install django-health-check

parent 0ce629ab
No related branches found
No related tags found
1 merge request!261Resolve "Implement django-health-check"
Pipeline #2052 passed
......@@ -63,6 +63,11 @@ INSTALLED_APPS = [
"polymorphic",
"django_global_request",
"dbbackup",
"health_check",
"health_check.db",
"health_check.cache",
"health_check.storage",
"health_check.contrib.psutil",
"settings_context_processor",
"sass_processor",
"easyaudit",
......@@ -648,6 +653,7 @@ elif HAYSTACK_BACKEND_SHORT == "whoosh":
if _settings.get("celery.enabled", False) and _settings.get("search.celery", True):
INSTALLED_APPS.append("celery_haystack")
INSTALLED_APPS.append("health_check.contrib.celery")
HAYSTACK_SIGNAL_PROCESSOR = "celery_haystack.signals.CelerySignalProcessor"
else:
HAYSTACK_SIGNAL_PROCESSOR = "haystack.signals.RealtimeSignalProcessor"
......@@ -655,3 +661,8 @@ else:
HAYSTACK_SEARCH_RESULTS_PER_PAGE = 10
DJANGO_EASY_AUDIT_WATCH_REQUEST_EVENTS = False
HEALTH_CHECK = {
"DISK_USAGE_MAX": _settings.get("health.disk_usage_max_percent", 90),
"MEMORY_MIN": _settings.get("health.memory_min_mb", 500),
}
......@@ -9,6 +9,7 @@ from django.views.i18n import JavaScriptCatalog
import calendarweek.django
import debug_toolbar
from django_js_reverse.views import urls_js
from health_check.urls import urlpatterns as health_urls
from two_factor.urls import urlpatterns as tf_urls
from . import views
......@@ -119,6 +120,7 @@ urlpatterns = [
{"registry_name": "group"},
name="preferences_group",
),
path("health/", include(health_urls)),
]
# Serve static files from STATIC_ROOT to make it work with runserver
......
......@@ -85,6 +85,8 @@ spdx-license-list = "^0.4.0"
license-expression = "^1.2"
django-reversion = "^3.0.7"
django-favicon-plus-reloaded = "^1.0.4"
django-health-check = "^3.12.1"
psutil = "^5.7.0"
[tool.poetry.extras]
ldap = ["django-auth-ldap"]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment