summaryrefslogtreecommitdiff
path: root/package/system
diff options
context:
space:
mode:
authorJohn Crispin <john@openwrt.org>2014-07-01 10:26:10 +0000
committerJohn Crispin <john@openwrt.org>2014-07-01 10:26:10 +0000
commitea535a9565bd22327cf95e74d13400c8bfb2d523 (patch)
tree9ef1e1e6920d575a8a550ed4ef7d0c461f248b63 /package/system
parentbf75e37030746e777116781dd4236a7f6d29aabd (diff)
downloadmtk-20170518-ea535a9565bd22327cf95e74d13400c8bfb2d523.zip
mtk-20170518-ea535a9565bd22327cf95e74d13400c8bfb2d523.tar.gz
mtk-20170518-ea535a9565bd22327cf95e74d13400c8bfb2d523.tar.bz2
ubox: add a flag that allows us to disable remote log while keeping the ip settings inside uci
this makes webui foo a lot easier Signed-off-by: John Crispin <blogic@openwrt.org> SVN-Revision: 41439
Diffstat (limited to 'package/system')
-rw-r--r--package/system/ubox/files/log.init4
1 files changed, 3 insertions, 1 deletions
diff --git a/package/system/ubox/files/log.init b/package/system/ubox/files/log.init
index e11a74b..a4d57e2 100644
--- a/package/system/ubox/files/log.init
+++ b/package/system/ubox/files/log.init
@@ -15,6 +15,7 @@ validate_log_section()
'log_file:string' \
'log_size:uinteger' \
'log_ip:ipaddr' \
+ 'log_remote:bool:1' \
'log_port:port:514' \
'log_proto:or("tcp", "udp"):udp' \
'log_prefix:string'
@@ -64,12 +65,13 @@ start_service_remote()
{
PIDCOUNT="$(( ${PIDCOUNT} + 1))"
local pid_file="/var/run/logread.${PIDCOUNT}.pid"
- local log_ip log_port log_proto log_prefix
+ local log_ip log_port log_proto log_prefix log_remote
validate_log_section "${1}" || {
echo "validation failed"
return 1
}
+ [ "${log_enable}" -ne 0 ] || return
[ -z "${log_ip}" ] && return
procd_open_instance