]> git.pld-linux.org Git - packages/cherokee.git/commitdiff
- log output and workaround for broken -b
authorElan Ruusamäe <glen@pld-linux.org>
Sat, 31 Dec 2005 15:55:21 +0000 (15:55 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    cherokee.init -> 1.3

cherokee.init

index e52bdde25fe9a2c9e4682b12f03e31a761bf27ea..911c693470cf16347f76f067ef2682e8b9125ebc 100644 (file)
@@ -33,9 +33,17 @@ case "$1" in
        # Check if the service is already running?
        if [ ! -f /var/lock/subsys/cherokee ]; then
                msg_starting "Cherokee Web Server"
-               start-stop-daemon --start --exec /usr/sbin/cherokee --background --pidfile /var/run/cherokee.pid
+               (
+               # it offers no stdout/stderr logging. workaround
+               exec 2>>/var/log/cherokee/cherokee.log
+               exec 1>&2
+               start-stop-daemon --start --exec /usr/sbin/cherokee --pidfile /var/run/cherokee.pid -- -b
+               )
                RETVAL=$?
                if [ $RETVAL -eq 0 ]; then
+                       # the pidfile written is wrong when cherokee -b is used. damn
+                       pid=$(/sbin/pidof cherokee)
+                       echo $pid > /var/run/cherokee.pid
                        touch /var/lock/subsys/cherokee
                        ok
                else
This page took 0.097229 seconds and 4 git commands to generate.