Lines 16-31
rcvar=minidlna_enable
Link Here
|
16 |
load_rc_config $name |
16 |
load_rc_config $name |
17 |
|
17 |
|
18 |
minidlna_enable=${minidlna_enable-"NO"} |
18 |
minidlna_enable=${minidlna_enable-"NO"} |
19 |
minidlna_uid=${minidlna_uid-"%%USER%%"} |
19 |
minidlna_user=${minidlna_user-"%%USER%%"} |
20 |
|
20 |
|
21 |
command=%%PREFIX%%/sbin/minidlnad |
21 |
command=%%PREFIX%%/sbin/minidlnad |
22 |
pidfile="/var/run/minidlna/minidlna.pid" |
22 |
pidfile="/var/run/minidlna/minidlna.pid" |
23 |
command_args="-P $pidfile -u $minidlna_uid -f %%PREFIX%%/etc/minidlna.conf" |
23 |
command_args="-P $pidfile -f %%PREFIX%%/etc/minidlna.conf" |
24 |
|
24 |
|
25 |
start_precmd="install -d -o $minidlna_uid ${pidfile%/*} /var/db/minidlna" |
25 |
start_precmd="install -d -o $minidlna_user ${pidfile%/*} /var/db/minidlna" |
26 |
stop_postcmd="rm -f $pidfile" |
26 |
stop_postcmd="rm -f $pidfile" |
27 |
|
27 |
|
28 |
extra_commands=rescan |
28 |
extra_commands=rescan |
29 |
rescan_cmd="$command -R -u $minidlna_uid -f %%PREFIX%%/etc/minidlna.conf" |
29 |
rescan_cmd="$command -R -f %%PREFIX%%/etc/minidlna.conf" |
30 |
|
30 |
|
31 |
run_rc_command $1 |
31 |
run_rc_command $1 |