Rework the config to use runit logging.

This commit is contained in:
Jake Moshenko 2014-05-18 17:19:14 -04:00
parent 334b4634d7
commit 212a4650f4
29 changed files with 58 additions and 165 deletions

2
conf/init/diffsworker/log/run Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd /var/log/diffsworker/

View file

@ -3,6 +3,6 @@
echo 'Starting diffs worker'
cd /
venv/bin/python -m workers.diffsworker --log=/mnt/logs/diffsworker.log
venv/bin/python -m workers.diffsworker
echo 'Diffs worker exited'

View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd /var/log/dockerfilebuild/

2
conf/init/gunicorn/log/run Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd /var/log/gunicorn/

View file

@ -1,4 +0,0 @@
#! /bin/sh
echo 'Creating logs directory'
mkdir -p /mnt/logs

2
conf/init/nginx/log/run Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd /var/log/nginx/

8
conf/init/preplogsdir.sh Executable file
View file

@ -0,0 +1,8 @@
#! /bin/sh
echo 'Linking config files to logs directory'
for svc in `ls /etc/service/`
do
mkdir -p /var/log/$svc
ln -s /svlogd_config /var/log/$svc/config
done

2
conf/init/svlogd_config Normal file
View file

@ -0,0 +1,2 @@
s100000000
t86400

2
conf/init/tutumdocker/log/run Executable file
View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd /var/log/tutumdocker/

View file

@ -92,6 +92,5 @@ if [ "$PORT" ]
then
exec docker -d -H 0.0.0.0:$PORT
else
docker -d -D -e lxc
docker -d -D -e lxc 2>&1
fi

View file

@ -0,0 +1,2 @@
#!/bin/sh
exec svlogd -t /var/log/webhookworker/

View file

@ -3,6 +3,6 @@
echo 'Starting webhook worker'
cd /
venv/bin/python -m workers.webhookworker --log=/mnt/logs/webhookworker.log
venv/bin/python -m workers.webhookworker
echo 'Webhook worker exited'