You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
431 B
39 lines
431 B
#!/bin/sh
|
|
|
|
. /etc/init.d/globals
|
|
|
|
start() {
|
|
if [ -e /var/etc/.minidlnad ]; then
|
|
minidlnad "$@"
|
|
fi
|
|
}
|
|
|
|
stop() {
|
|
if [ -e /var/etc/.minidlnad ]; then
|
|
kill -TERM $(pidof minidlnad)
|
|
fi
|
|
}
|
|
|
|
restart() {
|
|
stop
|
|
sleep 1
|
|
start "$@"
|
|
}
|
|
|
|
case "$1" in
|
|
start)
|
|
start
|
|
;;
|
|
stop)
|
|
stop
|
|
;;
|
|
restart|reload)
|
|
restart
|
|
;;
|
|
force-reload)
|
|
restart -R
|
|
;;
|
|
*)
|
|
echo "[$BASENAME] Usage: $0 {start|restart|reload|force-reload|stop}"
|
|
;;
|
|
esac
|
|
|