Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- . /etc/rc.common
- run=(/usr/local/bin/synergyc -n $(hostname -s) -1 -f synergy-server)
- KeepAlive ()
- {
- proc=${1##*/}
- while [ -x "$1" ] do
- if ! ps axco command | grep -q "^${proc}\$"
- then
- "$@"
- fi
- sleep 3
- done
- }
- StartService ()
- {
- ConsoleMessage "Starting Synergy"
- KeepAlive "${run[@]}" &
- }
- StopService ()
- {
- return 0
- }
- RestartService ()
- {
- return 0
- }
- RunService "$1"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement