From 700cc67a9aee27c903f3d55f72c113a643219a5d Mon Sep 17 00:00:00 2001 From: Joe Banks Date: Fri, 3 Sep 2021 22:35:21 +0100 Subject: Add gunicorn.conf.py with Prometheus specific settings --- gunicorn.conf.py | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 gunicorn.conf.py diff --git a/gunicorn.conf.py b/gunicorn.conf.py new file mode 100644 index 00000000..c60b64eb --- /dev/null +++ b/gunicorn.conf.py @@ -0,0 +1,5 @@ +# Code taken from https://github.com/prometheus/client_python#multiprocess-mode-eg-gunicorn +from prometheus_client import multiprocess + +def child_exit(server, worker): + multiprocess.mark_process_dead(worker.pid) -- cgit v1.2.3