0001-debian-use-uwsgi-to-serve-app-29297.patch
debian/authentic2-multitenant-uwsgi.ini | ||
---|---|---|
1 |
[uwsgi] |
|
2 |
auto-procname = true |
|
3 |
procname-prefix-spaced = authentic2-multitenant |
|
4 |
strict = true |
|
5 | ||
6 |
plugin = python3 |
|
7 |
single-interpreter = true |
|
8 |
module = authentic2.wsgi:application |
|
9 |
need-app = true |
|
10 | ||
11 |
http-socket = /run/authentic2-multitenant/authentic2-multitenant.sock |
|
12 |
chmod-socket = 666 |
|
13 |
vacuum = true |
|
14 | ||
15 |
master = true |
|
16 |
enable-threads = true |
|
17 |
harakiri = 120 |
|
18 | ||
19 |
processes = 500 |
|
20 | ||
21 |
plugin = cheaper_busyness |
|
22 |
cheaper-algo = busyness |
|
23 |
cheaper = 5 |
|
24 |
cheaper-initial = 10 |
|
25 |
cheaper-overload = 5 |
|
26 |
cheaper-step = 10 |
|
27 |
cheaper-busyness-multiplier = 30 |
|
28 |
cheaper-busyness-min = 20 |
|
29 |
cheaper-busyness-max = 70 |
|
30 |
cheaper-busyness-backlog-alert = 16 |
|
31 |
cheaper-busyness-backlog-step = 2 |
|
32 | ||
33 |
max-requests = 500 |
|
34 |
max-worker-lifetime = 7200 |
|
35 | ||
36 |
buffer-size = 32768 |
|
37 | ||
38 |
py-tracebacker = /run/authentic2-multitenant/py-tracebacker.sock. |
|
39 |
stats = /run/authentic2-multitenant/stats.sock |
|
40 | ||
41 |
ignore-sigpipe = true |
|
42 | ||
43 |
if-file = /etc/authentic2-multitenant/uwsgi-local.ini |
|
44 |
include = /etc/authentic2-multitenant/uwsgi-local.ini |
|
45 |
endif = |
debian/authentic2-multitenant.install | ||
---|---|---|
1 | 1 |
debian/multitenant/authentic2-multitenant-manage /usr/bin |
2 | 2 |
debian/multitenant/config.py /etc/authentic2-multitenant |
3 | 3 |
debian/multitenant/debian_config.py /usr/lib/authentic2-multitenant |
4 |
debian/authentic2-multitenant-uwsgi.ini /etc/authentic2-multitenant |
debian/authentic2-multitenant.service | ||
---|---|---|
10 | 10 |
Group=authentic-multitenant |
11 | 11 |
ExecStartPre=/usr/bin/authentic2-multitenant-manage migrate_schemas --noinput |
12 | 12 |
ExecStartPre=/usr/bin/authentic2-multitenant-manage collectstatic --noinput |
13 |
ExecStart=/usr/bin/gunicorn3 \ |
|
14 |
--bind unix:/run/%p/%p.sock \ |
|
15 |
--worker-class=sync \ |
|
16 |
--workers 5 \ |
|
17 |
--timeout=60 \ |
|
18 |
--name %p \ |
|
19 |
authentic2.wsgi:application |
|
13 |
ExecStart=/usr/bin/uwsgi --ini /etc/%p/%p-uwsgi.ini |
|
20 | 14 |
ExecReload=/bin/kill -HUP $MAINPID |
15 |
KillSignal=SIGQUIT |
|
21 | 16 |
TimeoutStartSec=0 |
22 | 17 |
PrivateTmp=true |
23 | 18 |
Restart=on-failure |
24 | 19 |
RuntimeDirectory=%p |
20 |
Type=notify |
|
21 |
StandardError=syslog |
|
22 |
NotifyAccess=all |
|
25 | 23 | |
26 | 24 |
[Install] |
27 | 25 |
WantedBy=multi-user.target |
debian/authentic2-uwsgi.ini | ||
---|---|---|
1 |
[uwsgi] |
|
2 |
auto-procname = true |
|
3 |
procname-prefix-spaced = authentic2 |
|
4 |
strict = true |
|
5 | ||
6 |
plugin = python3 |
|
7 |
single-interpreter = true |
|
8 |
module = authentic2.wsgi:application |
|
9 |
need-app = true |
|
10 | ||
11 |
http-socket = /run/authentic2/authentic2.sock |
|
12 |
chmod-socket = 666 |
|
13 |
vacuum = true |
|
14 | ||
15 |
master = true |
|
16 |
enable-threads = true |
|
17 |
harakiri = 120 |
|
18 | ||
19 |
processes = 500 |
|
20 | ||
21 |
plugin = cheaper_busyness |
|
22 |
cheaper-algo = busyness |
|
23 |
cheaper = 5 |
|
24 |
cheaper-initial = 10 |
|
25 |
cheaper-overload = 5 |
|
26 |
cheaper-step = 10 |
|
27 |
cheaper-busyness-multiplier = 30 |
|
28 |
cheaper-busyness-min = 20 |
|
29 |
cheaper-busyness-max = 70 |
|
30 |
cheaper-busyness-backlog-alert = 16 |
|
31 |
cheaper-busyness-backlog-step = 2 |
|
32 | ||
33 |
max-requests = 500 |
|
34 |
max-worker-lifetime = 7200 |
|
35 | ||
36 |
buffer-size = 32768 |
|
37 | ||
38 |
py-tracebacker = /run/authentic2/py-tracebacker.sock. |
|
39 |
stats = /run/authentic2/stats.sock |
|
40 | ||
41 |
ignore-sigpipe = true |
|
42 | ||
43 |
if-file = /etc/authentic2/uwsgi-local.ini |
|
44 |
include = /etc/authentic2/uwsgi-local.ini |
|
45 |
endif = |
debian/authentic2.install | ||
---|---|---|
3 | 3 |
debian/conf/nginx-example.conf /usr/share/authentic2 |
4 | 4 |
debian/debian_config.py /usr/lib/authentic2 |
5 | 5 |
debian/launch-authentic2.sh /usr/lib/authentic2 |
6 |
debian/authentic2-uwsgi.ini /etc/authentic2 |
debian/authentic2.service | ||
---|---|---|
10 | 10 |
Group=authentic2 |
11 | 11 |
ExecStartPre=/usr/bin/authentic2-manage migrate --noinput |
12 | 12 |
ExecStartPre=/usr/bin/authentic2-manage collectstatic --noinput |
13 |
ExecStart=/usr/lib/authentic2/launch-authentic2.sh \ |
|
14 |
--bind unix:/run/%p/%p.sock \ |
|
15 |
--worker-class=sync \ |
|
16 |
--workers 5 \ |
|
17 |
--timeout=60 \ |
|
18 |
--name %p \ |
|
19 |
authentic2.wsgi:application |
|
13 |
ExecStart=/usr/bin/uwsgi --ini /etc/%p/%p-uwsgi.ini |
|
20 | 14 |
ExecReload=/bin/kill -HUP $MAINPID |
15 |
KillSignal=SIGQUIT |
|
21 | 16 |
TimeoutStartSec=0 |
22 | 17 |
PrivateTmp=true |
23 | 18 |
Restart=on-failure |
24 | 19 |
RuntimeDirectory=%p |
20 |
Type=notify |
|
21 |
StandardError=syslog |
|
22 |
NotifyAccess=all |
|
25 | 23 | |
26 | 24 |
[Install] |
27 | 25 |
WantedBy=multi-user.target |
debian/control | ||
---|---|---|
55 | 55 |
Depends: ${misc:Depends}, adduser, |
56 | 56 |
python3-authentic2 (= ${binary:Version}), |
57 | 57 |
python3-psycopg2, |
58 |
gunicorn3, dbconfig-common, |
|
58 |
uwsgi, |
|
59 |
uwsgi-plugin-python3, |
|
60 |
dbconfig-common, |
|
59 | 61 |
debconf | debconf-2.0, ucf |
60 | 62 |
Recommends: postgresql-client |
61 | 63 |
Suggests: nginx, postgresql |
... | ... | |
75 | 77 |
python3-django-tenant-schemas (>= 1.5.2.1), |
76 | 78 |
python3-hobo, |
77 | 79 |
python3-jwcrypto (>= 0.4.2), |
78 |
gunicorn3, |
|
80 |
uwsgi, |
|
81 |
uwsgi-plugin-python3, |
|
79 | 82 |
debconf | debconf-2.0, ucf |
80 | 83 |
Recommends: postgresql-client |
81 | 84 |
Suggests: nginx, postgresql |
82 |
- |