hiawatha.rc 487 B

12345678910111213141516171819202122232425262728293031323334
  1. #!/bin/sh
  2. #
  3. # /etc/rc.d/hiawatha: başlatma/durdurma hiawatha web sunucu
  4. #
  5. . /lib/lsb/init-functions
  6. _PID=/var/run/hiawatha.pid
  7. case $1 in
  8. start)
  9. log_info_msg "Hiawatha başlatılıyor..."
  10. /usr/bin/hiawatha
  11. evaluate_retval
  12. ;;
  13. stop)
  14. log_info_msg "Hiawatha durduruluyor..."
  15. if [ -f $_PID ]; then
  16. kill `cat $_PID`
  17. else
  18. killall -9 /usr/bin/hiawatha
  19. fi
  20. evaluate_retval
  21. ;;
  22. restart)
  23. $0 stop
  24. sleep 2
  25. $0 start
  26. ;;
  27. *)
  28. echo "Kullanım: $0 [start|stop|restart]"
  29. exit 1
  30. ;;
  31. esac