Skip to content

Commit 5fd7910

Browse files
committed
systemd: docs: recommend Type=notify-reload
1 parent 88b5a10 commit 5fd7910

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

docs/source/deploy.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,8 @@ to the newly created unix socket:
247247

248248
[Service]
249249
# gunicorn can let systemd know when it is ready
250-
Type=notify
250+
# if systemd versions >= v253, otherwise use 'Type=notify'
251+
Type=notify-reload
251252
NotifyAccess=main
252253
# the specific user that our service will run as
253254
User=someuser
@@ -257,7 +258,8 @@ to the newly created unix socket:
257258
RuntimeDirectory=gunicorn
258259
WorkingDirectory=/home/someuser/applicationroot
259260
ExecStart=/usr/bin/gunicorn applicationname.wsgi
260-
ExecReload=/bin/kill -s HUP $MAINPID
261+
# if 'Type=notify' instead of 'Type=notify-reload' (depending on systemd version)
262+
# ExecReload=/bin/kill -s HUP $MAINPID
261263
KillMode=mixed
262264
TimeoutStopSec=5
263265
PrivateTmp=true

0 commit comments

Comments
 (0)