debian: add uwsgi spooler (#55570)
This commit is contained in:
parent
aec0edb0c8
commit
6432625ff2
|
@ -25,6 +25,7 @@ Depends: ${misc:Depends},
|
|||
python3-django-tenant-schemas,
|
||||
python3-psycopg2,
|
||||
python3-django-mellon,
|
||||
python3-uwsgidecorators,
|
||||
python3-xstatic-select2,
|
||||
uwsgi,
|
||||
uwsgi-plugin-python3,
|
||||
|
|
|
@ -9,6 +9,9 @@ http-socket = /run/welco/welco.sock
|
|||
chmod-socket = 666
|
||||
vacuum = true
|
||||
|
||||
spooler-processes = 3
|
||||
spooler-max-tasks = 20
|
||||
|
||||
master = true
|
||||
processes = 5
|
||||
harakiri = 120
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
/etc/welco
|
||||
/usr/lib/welco
|
||||
/var/lib/welco/collectstatic
|
||||
/var/lib/welco/spooler
|
||||
/var/lib/welco/tenants
|
||||
/var/log/welco
|
||||
|
|
|
@ -38,6 +38,7 @@ GROUP=$NAME
|
|||
DAEMON_ARGS=${DAEMON_ARGS:-"--pidfile=$PIDFILE
|
||||
--uid $USER --gid $GROUP
|
||||
--ini /etc/$NAME/uwsgi.ini
|
||||
--spooler /var/lib/$NAME/spooler/
|
||||
--daemonize /var/log/uwsgi.$NAME.log"}
|
||||
|
||||
# Load the VERBOSE setting and other rcS variables
|
||||
|
|
|
@ -20,6 +20,7 @@ case "$1" in
|
|||
# ensure dirs ownership
|
||||
chown $USER:$GROUP /var/log/$NAME
|
||||
chown $USER:$GROUP /var/lib/$NAME/collectstatic
|
||||
chown $USER:$GROUP /var/lib/$NAME/spooler
|
||||
chown $USER:$GROUP /var/lib/$NAME/tenants
|
||||
# create a secret file
|
||||
SECRET_FILE=$CONFIG_DIR/secret
|
||||
|
|
|
@ -10,7 +10,8 @@ User=%p
|
|||
Group=%p
|
||||
ExecStartPre=/usr/bin/welco-manage migrate_schemas --noinput --verbosity 1
|
||||
ExecStartPre=/usr/bin/welco-manage collectstatic --noinput
|
||||
ExecStart=/usr/bin/uwsgi --ini /etc/%p/uwsgi.ini
|
||||
ExecStartPre=/bin/mkdir -p /var/lib/welco/spooler/%m/
|
||||
ExecStart=/usr/bin/uwsgi --ini /etc/%p/uwsgi.ini --spooler /var/lib/welco/spooler/%m/
|
||||
ExecReload=/bin/kill -HUP $MAINPID
|
||||
KillSignal=SIGQUIT
|
||||
TimeoutStartSec=0
|
||||
|
|
Loading…
Reference in New Issue