home *** CD-ROM | disk | FTP | other *** search
/ Dream 52 / Amiga_Dream_52.iso / Linux / Magazine / wwwoffle-2.1.tar.gz / wwwoffle-2.1 / contrib / debian-start-stop1 next >
Text File  |  1997-12-19  |  957b  |  38 lines

  1. #! /bin/sh
  2. # wwwoffled    script to go e.g., into /etc/init.d/ scripts.
  3. #
  4. #               Modified by Joerg Wittenberger <joerg.wittenberger@pobox.com>
  5. #               from skeleton
  6. #        file by Miquel van Smoorenburg <miquels@cistron.nl>.
  7. #        Modified for Debian GNU/Linux
  8. #        by Ian Murdock <imurdock@gnu.ai.mit.edu>.
  9. #
  10.  
  11. PATH=/usr/local/sbin:/sbin:/bin:/usr/sbin:/usr/bin
  12. NAME=wwwoffled
  13. DAEMON=/usr/sbin/$NAME
  14.  
  15. test -f $DAEMON || exit 0
  16.  
  17. set -e
  18.  
  19. case "$1" in
  20.   start)
  21.     start-stop-daemon --start --verbose --pidfile /var/run/$NAME.pid --exec $DAEMON &
  22.     ;;
  23.   stop)
  24.     start-stop-daemon --stop --verbose --pidfile /var/run/$NAME.pid --exec $DAEMON
  25.     ;;
  26.   reload)
  27.     # echo "Reloading $NAME configuration files"
  28.     # start-stop-daemon --stop --signal 1 --quiet --pidfile /var/run/$NAME.pid --exec $DAEMON
  29.     ;;
  30.   *)
  31.     # echo "Usage: /etc/init.d/$NAME {start|stop|reload}"
  32.     echo "Usage: /etc/init.d/$NAME {start|stop}"
  33.     exit 1
  34.     ;;
  35. esac
  36.  
  37. exit 0
  38.