S50dante 600 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #!/bin/sh
  2. #
  3. # Starts dante
  4. #
  5. # Allow a few customizations from a config file
  6. test -r /etc/default/dante && . /etc/default/dante
  7. start() {
  8. printf "Starting dante: "
  9. start-stop-daemon -S -q -p /var/run/dante.pid \
  10. --exec /usr/sbin/sockd -- $DAEMON_ARGS
  11. [ $? = 0 ] && echo "OK" || echo "FAIL"
  12. }
  13. stop() {
  14. printf "Stopping dante: "
  15. start-stop-daemon -K -q -p /var/run/dante.pid
  16. [ $? = 0 ] && echo "OK" || echo "FAIL"
  17. }
  18. restart() {
  19. stop
  20. start
  21. }
  22. case "$1" in
  23. start)
  24. start
  25. ;;
  26. stop)
  27. stop
  28. ;;
  29. restart|reload)
  30. restart
  31. ;;
  32. *)
  33. echo "Usage: $0 {start|stop|restart}"
  34. exit 1
  35. esac
  36. exit $?