27 lines
615 B
SYSTEMD
27 lines
615 B
SYSTEMD
[Unit]
|
|
Description=Netbox uWSGI WSGI Service
|
|
Documentation=https://netbox.readthedocs.io/en/stable/
|
|
PartOf=netbox.service
|
|
After=netbox.service
|
|
After=network.target
|
|
Wants=network.target
|
|
|
|
[Service]
|
|
Type=simple
|
|
|
|
User=netbox
|
|
Group=netbox
|
|
WorkingDirectory=/opt/netbox
|
|
|
|
ExecStart=/opt/netbox/venv/bin/uwsgi --master --chdir /opt/netbox/netbox --module netbox.wsgi uwsgi.ini
|
|
# signals: https://uwsgi-docs.readthedocs.io/en/latest/Management.html#signals-for-controlling-uwsgi
|
|
ExecReload=kill -HUP $MAINPID
|
|
ExecStop=kill -INT $MAINPID
|
|
KillSignal=SIGQUIT
|
|
|
|
Restart=on-failure
|
|
RestartSec=30
|
|
|
|
[Install]
|
|
WantedBy=netbox.service
|