pandora/etc/init/pandora.conf

25 lines
623 B
Text
Raw Normal View History

2010-09-14 17:04:27 +00:00
# pandora gunicorn daemon
#
description "pandora daemon"
start on runlevel [2345]
stop on runlevel [!2345]
2010-11-11 22:52:03 +00:00
kill timeout 5
2010-09-14 17:04:27 +00:00
respawn
2010-11-11 22:52:03 +00:00
env VENV=/srv/pandora
env USER=pandora
env HOME=/home/pandora
2010-09-14 17:04:27 +00:00
2010-11-11 22:52:03 +00:00
script
2010-11-30 21:41:58 +00:00
test -e /var/log/pandora || (mkdir -p /var/log/pandora && chown $USER:$USER /var/log/pandora)
2010-11-11 22:52:03 +00:00
cd $VENV/pandora
2010-11-30 21:41:58 +00:00
exec /usr/bin/sudo -u $USER $VENV/bin/gunicorn_django \
2010-12-23 12:30:10 +00:00
--bind 127.0.0.1:2620 \
--timeout 90 \
2010-11-30 21:41:58 +00:00
--log-level info --log-file /var/log/pandora/pandora.log \
2010-12-23 12:30:10 +00:00
--workers 5 \
$VENV/pandora/settings.py
2010-11-11 22:52:03 +00:00
end script