Advertisement
icoexist

init script for SoftEther VPN Server

Oct 24th, 2017
7,671
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. echo '#!/bin/sh
  2. # description: SoftEther VPN Server
  3. ### BEGIN INIT INFO
  4. # Provides: vpnserver
  5. # Required-Start: $local_fs $network
  6. # Required-Stop: $local_fs
  7. # Default-Start: 2 3 4 5
  8. # Default-Stop: 0 1 6
  9. # Short-Description: softether vpnserver
  10. # Description: softether vpnserver daemon
  11. ### END INIT INFO
  12. DAEMON=/usr/local/vpnserver/vpnserver
  13. LOCK=/var/lock/subsys/vpnserver
  14. test -x $DAEMON || exit 0
  15. case "$1" in
  16. start)
  17. $DAEMON start
  18. touch $LOCK
  19. ;;
  20. stop)
  21. $DAEMON stop
  22. rm $LOCK
  23. ;;
  24. restart)
  25. $DAEMON stop
  26. sleep 3
  27. $DAEMON start
  28. ;;
  29. *)
  30. echo "Usage: $0 {start|stop|restart}"
  31. exit 1
  32. esac
  33. exit 0' > /etc/init.d/vpnserver
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement