Skip to content

Commit

Permalink
feat: Use systemd notify service type
Browse files Browse the repository at this point in the history
For type=forking without PID file, systemd has to "guess" main pid, and this might not work in some cases.
  • Loading branch information
taoky committed Aug 7, 2024
1 parent ef6f6fc commit bbafec3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions conf/systemd/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@ Description=Hackergame Platform (%i)
After=syslog.target

[Service]
ExecStart=/opt/%i/.venv/bin/uwsgi --ini /opt/%i/conf/uwsgi-apps/%i.ini --ini /opt/%i/conf/uwsgi.ini --set-placeholder appname=%i --daemonize /var/log/uwsgi/app/%i.log
ExecStart=/opt/%i/.venv/bin/uwsgi --ini /opt/%i/conf/uwsgi-apps/%i.ini --ini /opt/%i/conf/uwsgi.ini --set-placeholder appname=%i --logto /var/log/uwsgi/app/%i.log
ExecReload=/bin/kill -HUP $MAINPID
LogsDirectory=uwsgi/app
RuntimeDirectory=uwsgi/app/%i
Restart=always
KillSignal=SIGQUIT
Type=forking
Type=notify
NotifyAccess=all
User=www-data
Group=www-data

Expand Down

0 comments on commit bbafec3

Please sign in to comment.