Permalink
Browse files

Move log output to /var/log/statsd logging in /tmp is not a good idea…

…, it's dangerous and not persitent in many cases (/tmp mount in tmpfs or wiped at host startup).
  • Loading branch information...
1 parent cc1ba1f commit 15d147ba30531b9c567512f18bce6e6ad550a21a Bruno Clermont committed with kastner Sep 2, 2011
Showing with 8 additions and 1 deletion.
  1. +1 −0 debian/dirs
  2. +6 −0 debian/postinst
  3. +1 −1 debian/scripts/start
View
1 debian/dirs
@@ -0,0 +1 @@
+var/log/statsd
View
6 debian/postinst
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+if [ "`stat -c %G /var/log/statsd`" != 'nogroup' ]; then
+ chown root.nogroup /var/log/statsd
+ chmod 770 /var/log/statsd
+fi
View
2 debian/scripts/start
@@ -1,3 +1,3 @@
#!/bin/sh
# Called by Upstart, /etc/init/statsd.conf
-/usr/bin/nodejs /usr/share/statsd/stats.js /etc/statsd/rdioConfig.js 2>&1 >> /tmp/statsd.log
+/usr/bin/nodejs /usr/share/statsd/stats.js /etc/statsd/rdioConfig.js 2>&1 >> /var/log/statsd/statsd.log

0 comments on commit 15d147b

Please sign in to comment.