mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-23 01:12:57 +02:00
Add ushare package and libdlna
This commit is contained in:
51
src/initscripts/init.d/ushare
Normal file
51
src/initscripts/init.d/ushare
Normal file
@@ -0,0 +1,51 @@
|
||||
#!/bin/sh
|
||||
########################################################################
|
||||
# Begin $rc_base/init.d/
|
||||
#
|
||||
# Description : ushare initscript
|
||||
#
|
||||
# Authors : Arne Fitzenreiter
|
||||
#
|
||||
# Version : 01.00
|
||||
#
|
||||
# Notes : for www.ipfire.org - GPLv3
|
||||
#
|
||||
########################################################################
|
||||
|
||||
. /etc/sysconfig/rc
|
||||
. ${rc_functions}
|
||||
|
||||
case "$1" in
|
||||
start)
|
||||
boot_mesg "Starting uShare uPnP Mediaserver..."
|
||||
route add -net 239.0.0.0 netmask 255.0.0.0 green0
|
||||
loadproc sudo -u nobody /usr/bin/ushare -n $(hostname -f) \
|
||||
-i green0 --no-web --no-telnet \
|
||||
-c /var/mp3 -c /var/video -D > /dev/null 2>&1
|
||||
evaluate_retval
|
||||
;;
|
||||
|
||||
stop)
|
||||
boot_mesg "Stopping uShare uPnP Mediaserver..."
|
||||
killproc /usr/bin/ushare
|
||||
evaluate_retval
|
||||
route del -net 239.0.0.0 netmask 255.0.0.0 green0
|
||||
;;
|
||||
|
||||
restart)
|
||||
${0} stop
|
||||
sleep 1
|
||||
${0} start
|
||||
|
||||
;;
|
||||
status)
|
||||
statusproc
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "Usage: ${0} {start|stop|reload|restart|status}"
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
# End $rc_base/init.d/
|
||||
Reference in New Issue
Block a user