feat(api): replace uwsgi with gunicorn (#1785)
Related to #1719 BREAKING: The uwsgi packages and configuration files (`/etc/airtime/libretime-api.ini`) should be removed from the system.
This commit is contained in:
parent
e320ce204e
commit
41df76eed0
5 changed files with 24 additions and 21 deletions
|
@ -3,13 +3,18 @@ Description=LibreTime API Service
|
|||
|
||||
[Service]
|
||||
Type=notify
|
||||
NotifyAccess=all
|
||||
KillSignal=SIGQUIT
|
||||
KillMode=mixed
|
||||
PrivateTmp=true
|
||||
|
||||
Environment=LIBRETIME_LOG_FILEPATH=/var/log/libretime/api.log
|
||||
Environment=LIBRETIME_CONFIG_FILEPATH=/etc/airtime/airtime.conf
|
||||
|
||||
ExecStart=/usr/bin/uwsgi /etc/airtime/libretime-api.ini
|
||||
ExecStart=/usr/bin/gunicorn \
|
||||
--workers 4 \
|
||||
--log-file - \
|
||||
--bind 127.0.0.1:8081 \
|
||||
libretime_api.wsgi
|
||||
ExecReload=/bin/kill -s HUP $MAINPID
|
||||
User=libretime-api
|
||||
Group=libretime-api
|
||||
Restart=always
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
[uwsgi]
|
||||
module = libretime_api.wsgi
|
||||
|
||||
master = true
|
||||
plugin = python3
|
||||
processes = 10
|
||||
vacuum = true
|
||||
http-socket = :8081
|
||||
uid = WEB_USER
|
||||
gid = WEB_USER
|
|
@ -2,10 +2,8 @@
|
|||
[python]
|
||||
python3 = buster, bullseye, bionic, focal
|
||||
python3-pip = buster, bullseye, bionic, focal
|
||||
|
||||
[django]
|
||||
uwsgi = buster, bullseye, bionic, focal
|
||||
uwsgi-plugin-python3 = buster, bullseye, bionic, focal
|
||||
gunicorn = buster, bullseye, bionic, focal
|
||||
python3-gunicorn = buster, bullseye, bionic, focal
|
||||
|
||||
[psycopg2]
|
||||
# See https://www.psycopg.org/docs/install.html#install-from-source
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue