[packages] miniupnpd: Added uci option config_file, which allows the user to specify that miniupnpd should use the specified file as the configuration file instead of /etc/miniupnpd.conf or none if no /etc/miniupnpd.conf present

git-svn-id: svn://svn.openwrt.org/openwrt/packages@25899 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
cshore 2011-03-06 18:57:06 +00:00
parent 5bd0514866
commit 0c07ec43b5

View File

@ -7,7 +7,7 @@ start() {
config_load "upnpd" config_load "upnpd"
local extiface intiface upload download logging secure enabled natpmp local extiface intiface upload download logging secure enabled natpmp
local extip port usesystuptime local extip port usesysuptime conffile
config_get extiface config external_iface config_get extiface config external_iface
config_get intiface config internal_iface config_get intiface config internal_iface
@ -20,6 +20,7 @@ start() {
config_get_bool natpmp config enable_natpmp 0 config_get_bool natpmp config enable_natpmp 0
config_get_bool enabled config enabled 0 config_get_bool enabled config enabled 0
config_get_bool usesysuptime config use_system_uptime 1 config_get_bool usesysuptime config use_system_uptime 1
config_get conffile config config_file
include /lib/network include /lib/network
scan_interfaces scan_interfaces
@ -55,6 +56,9 @@ start() {
[ "$natpmp" -gt 0 ] && \ [ "$natpmp" -gt 0 ] && \
append args "-N" append args "-N"
[ -n "$conffile" ] && \
append args "-f $conffile"
# start firewall # start firewall
local zone local zone
config_load firewall config_load firewall