blob: df90bc5d6584003c93a3b95efc7e7cd44877b2f4 [file] [log] [blame]
{#
SPDX-FileCopyrightText: © 2020 Open Networking Foundation <support@opennetworking.org>
SPDX-License-Identifier: Apache-2.0
#}
[Unit]
Description=NetBox WSGI Service
Documentation=https://netbox.readthedocs.io/en/stable/
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
User={{ netbox_username }}
Group={{ netbox_groupname }}
PIDFile=/var/tmp/netbox.pid
WorkingDirectory={{ netbox_working_dir }}
ExecStart={{ netbox_working_dir }}/venv/bin/gunicorn --pid /var/tmp/netbox.pid --pythonpath {{ netbox_working_dir }}/netbox --config {{ netbox_working_dir }}/gunicorn.py netbox.wsgi
Restart=on-failure
RestartSec=30
PrivateTmp=true
[Install]
WantedBy=multi-user.target