yWeb: add possibility to get minidlna webif; thx to DdD

Origin commit data
------------------
Commit: b342b7e033
Author: vanhofen <vanhofen@gmx.de>
Date: 2021-01-23 (Sat, 23 Jan 2021)

Origin message was:
------------------
- yWeb: add possibility to get minidlna webif; thx to DdD
This commit is contained in:
vanhofen
2021-01-23 23:15:51 +01:00
parent b743820ff4
commit ba98c15305
2 changed files with 15 additions and 0 deletions

View File

@@ -333,6 +333,14 @@ case "$action" in
printf "%s" ${_port:-8080}
;;
get_minidlnad_webif_port)
if [ -e /etc/minidlna.conf ]; then
_port=$(grep -m 1 "^[:space:]*port=" /etc/minidlna.conf | cut -d'=' -f2)
_port=$(echo $_port | dos2unix -u)
fi
printf "%s" $_port
;;
get_xupnpd_webif_port)
if [ -e /share/xupnpd/xupnpd.lua ]; then
_port=$(grep -m 1 "^[:space:]*cfg.http_port" /share/xupnpd/xupnpd.lua | cut -d'=' -f2)