summaryrefslogtreecommitdiffstats
path: root/debian/welco.service
blob: e4ae3ca54a05f98b3c1a17a904dcdc564bb58a80 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
[Unit]
Description=Welco
After=network.target postgresql.service
Wants=postgresql.service

[Service]
Environment=WELCO_SETTINGS_FILE=/usr/lib/%p/debian_config.py
User=%p
Group=%p
ExecStartPre=/usr/bin/welco-manage migrate_schemas --noinput
ExecStartPre=/usr/bin/welco-manage collectstatic --noinput
ExecStart=/usr/bin/gunicorn \
          --bind unix:/run/%p/%p.sock \
          --worker-class=sync \
          --workers 5 \
          --timeout=30 \
          --name %p \
          %p.wsgi:application
ExecReload=/bin/kill -HUP $MAINPID
TimeoutStartSec=0
PrivateTmp=true
Restart=on-failure
RuntimeDirectory=welco

[Install]
WantedBy=multi-user.target