]> git.pld-linux.org Git - packages/distcc.git/commitdiff
- distcc init file
authormisi3k <misi3k@pld-linux.org>
Sun, 4 May 2003 13:26:51 +0000 (13:26 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    distcc.init -> 1.1

distcc.init [new file with mode: 0644]

diff --git a/distcc.init b/distcc.init
new file mode 100644 (file)
index 0000000..c2c6014
--- /dev/null
@@ -0,0 +1,74 @@
+#!/bin/sh
+#
+# $Id$
+#
+# distccd              distccd 
+#
+# chkconfig:   345 55 45
+#
+# description: distccd 
+#      
+
+
+# Source function library
+. /etc/rc.d/init.d/functions
+
+# Get network config
+. /etc/sysconfig/network
+
+# Get service config
+[ -f /etc/sysconfig/distccd ] && . /etc/sysconfig/distccd
+
+# Check that networking is up.
+if is_no "${NETWORKING}"; then
+        msg_network_down distccd
+        exit 1
+fi
+
+OPTION1="--daemon"
+                       
+
+# See how we were called.
+case "$1" in
+  start)
+       # Check if the service is already running?
+       if [ ! -f /var/lock/subsys/distccd ]; then
+               msg_starting distccd
+               daemon /usr/bin/distccd 
+               RETVAL=$?
+               [ $RETVAL -eq 0 ] && touch /var/lock/subsys/distccd             
+       else
+               msg_already_running distccd
+       fi
+       ;;
+  stop)
+        if [ -f /var/lock/subsys/distccd ]; then
+               msg_stopping distccd
+               killproc distccd
+               rm -f /var/run/distccd.pid /var/lock/subsys/distccd >/dev/null 2>&1
+       else
+               msg_not_running distccd
+               exit 1
+       fi      
+       ;;
+  restart)
+       $0 stop
+       $0 start
+       ;;
+  status)
+       status distccd
+       exit $?
+       ;;
+  reload)
+       msg_reloading distccd
+       killproc distccd -HUP
+       ;;
+  *)
+       msg_usage "$0 {start|stop|status|restart|reload}"
+       exit 1
+esac
+
+exit $RETVAL
+
+# This must be last line !
+# vi:syntax=sh:tw=78:ts=8:sw=4
This page took 0.059331 seconds and 4 git commands to generate.