32 lines
635 B
Desktop File
Executable File
32 lines
635 B
Desktop File
Executable File
#!/bin/sh
|
|
|
|
#--- import colors and init-funcs ---
|
|
. /usr/lib/init/colors.sh
|
|
. /usr/lib/init/init-funcs.sh
|
|
#------------------------------------
|
|
|
|
start() {
|
|
notify "Starting dns_service"
|
|
/usr/bin/dns_service &> /dev/null &
|
|
echo $(pgrep dns_service) > /var/run/dns_service.pid
|
|
check $? "start dns_service"
|
|
return $?
|
|
}
|
|
|
|
stop() {
|
|
notify "Stopping dns_service"
|
|
kill $(cat /var/run/dns_service.pid)
|
|
check $? "stop dns_service"
|
|
rm /var/run/dns_service.pid &> /dev/null
|
|
return $?
|
|
}
|
|
|
|
case "$1" in
|
|
start|stop|restart|reload|help)
|
|
"$1"
|
|
;;
|
|
*)
|
|
help
|
|
;;
|
|
esac
|
|
return $? |