summaryrefslogtreecommitdiff
path: root/distcc/distccd
blob: 21605bf0e84faf4099c7ca583df1c9ff445e8813 (plain)
    1 #!/bin/sh
    2 #
    3 # /etc/rc.d/distccd: start/stop distcc daemon
    4 #
    5 
    6 . /etc/rc.conf
    7 if [ -z "$DISTCC_ALLOW" ]; then 
    8     echo "Please define a range of IPs allowed to connect to this distccd"
    9     echo "host in DISTCC_ALLOW in /etc/rc.conf. More detailed information"
   10     echo "can be found in distccd's man page."
   11     exit -1
   12 fi
   13 DISTCC_USER=${DISTCC_USER:=nobody}
   14 
   15 case $1 in
   16 start)
   17 	/usr/bin/distccd --daemon --user $DISTCC_USER --allow $DISTCC_ALLOW
   18 	;;
   19 stop)
   20 	killall -q /usr/bin/distccd
   21 	;;
   22 restart)
   23 	$0 stop
   24 	$0 start
   25 	;;
   26 *)
   27 	echo "usage: $0 [start|stop|restart]"
   28 	;;
   29 esac
   30 
   31 # End of file

Generated by cgit