Display status and information of the system. Can be used as a heartbeat indicator for load balancer.
Install django-statuspage:
pip install django-statuspage
Then use it in a project:
import djstatuspage
- Display information about installed system with a simple json response
Add url in your project with
import djastatuspage
- urlpatterns += patterns('',
- url(r'^', include(djstatuspage.urls.urlpatterns, namespace='statuspage')),
)
- STATUSPAGE_TASKS - define extra callables to add to output in key-value
manner. For example.
STATUSPAGE_TASKS["version"] = lambda: "0.1.0"
Will return
{"database": "ok", "version": "0.1.0"}
- STATUSPAGE_TRY_DATABASE - Default True. Turn off database round trip.
- cookiecutter
- cookiecutter-djangopackage