Merge pull request #18037 from M95D/openwrt-21.02
tvheadend: bind to LAN IP by default
This commit is contained in:
commit
85b7d29c3e
2 changed files with 3 additions and 0 deletions
|
@ -5,6 +5,8 @@
|
||||||
|
|
||||||
config tvheadend server
|
config tvheadend server
|
||||||
option ipv6 '1'
|
option ipv6 '1'
|
||||||
|
# If bindaddr is not set, it will default to LAN IP address (uci get network.lan.ipaddr).
|
||||||
|
# To bind all interfaces, set it to "0.0.0.0".
|
||||||
# option bindaddr '0.0.0.0'
|
# option bindaddr '0.0.0.0'
|
||||||
# option http_port '9981'
|
# option http_port '9981'
|
||||||
# option http_root '/tvheadend'
|
# option http_root '/tvheadend'
|
||||||
|
|
|
@ -53,6 +53,7 @@ load_uci_config() {
|
||||||
config_get_bool ipv6 server ipv6 0
|
config_get_bool ipv6 server ipv6 0
|
||||||
[ "$ipv6" -eq 1 ] && procd_append_param command --ipv6
|
[ "$ipv6" -eq 1 ] && procd_append_param command --ipv6
|
||||||
config_get bindaddr server bindaddr
|
config_get bindaddr server bindaddr
|
||||||
|
[ -z "$bindaddr" ] && bindaddr=$(uci get network.lan.ipaddr)
|
||||||
[ -n "$bindaddr" ] && procd_append_param command --bindaddr "$bindaddr"
|
[ -n "$bindaddr" ] && procd_append_param command --bindaddr "$bindaddr"
|
||||||
config_get http_port server http_port
|
config_get http_port server http_port
|
||||||
[ -n "$http_port" ] && procd_append_param command --http_port "$http_port"
|
[ -n "$http_port" ] && procd_append_param command --http_port "$http_port"
|
||||||
|
|
Loading…
Reference in a new issue