Skip to content

Commit 3f9446f

Browse files
committed
Add stopping notification to systemd
1 parent 98869a1 commit 3f9446f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

gunicorn/arbiter.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,7 @@ def wakeup(self):
342342

343343
def halt(self, reason=None, exit_status=0):
344344
""" halt arbiter """
345+
systemd.sd_notify("STOPPING=1\nSTATUS=Gunicorn arbiter stopping", self.log)
345346
self.stop()
346347

347348
log_func = self.log.info if exit_status == 0 else self.log.error

0 commit comments

Comments
 (0)