luci-app-pushbot: update to 3.55-16 (#7869)

Signed-off-by: Beginner-Go <70857188+Beginner-Go@users.noreply.github.com>
This commit is contained in:
Beginner 2021-09-18 00:46:57 +08:00 committed by GitHub
parent 0b52435c36
commit 751dda88b9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 14 additions and 15 deletions

View File

@ -2,9 +2,9 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-pushbot
PKG_VERSION:=3.55
PKG_RELEASE:=15
PKG_RELEASE:=16
PKG_MAINTAINER:=tty228 zzsj0928
PKG_MAINTAINER:=tty228 <tty228@yeah.net> zzsj0928
LUCI_TITLE:=LuCI support for Pushbot
LUCI_PKGARCH:=all

View File

@ -2,5 +2,5 @@ f = SimpleForm("pushbot")
luci.sys.call("/usr/bin/pushbot/pushbot client")
f.reset = false
f.submit = false
f:append(Template("pushbot/client"))
f:append(Template("pushbot/pushbot_client"))
return f

View File

@ -1,5 +1,5 @@
f = SimpleForm("pushbot")
f.reset = false
f.submit = false
f:append(Template("pushbot/log"))
f:append(Template("pushbot/pushbot_log"))
return f

View File

@ -8,4 +8,3 @@ config pushbot 'pushbot'
option cpuload_enable '1'
option cpuload '2'
option temperature_enable '0'

View File

@ -3,4 +3,4 @@ ipv4.ddnspod.com
ifcfg.cn
speed.neu.edu.cn/getIP.php
ddns.oray.com/checkip
www.net.cn/static/customercare/yourip.asp
www.net.cn/static/customercare/yourip.asp

View File

@ -2,4 +2,4 @@ ip.sb
ipv6.ddnspod.com
api-ipv6.ip.sb/ip
speed.neu6.edu.cn/getIP.php
v6.myip.la/json
v6.myip.la/json

View File

@ -519,7 +519,7 @@ function get_client(){
local js_str="${js_str}<div class='th'><%:${tmp_uptime}%></div></div>"
done < ${dir}ipAddress
fi
cat>/usr/lib/lua/luci/view/pushbot/client.htm<<EOF
cat>/usr/lib/lua/luci/view/pushbot/pushbot_client.htm<<EOF
<h2><%:在线设备列表%></h2><div class="table" id="traffic"><div class="tr table-titles"><div class="th" id="thClient" style="width:17%"><%:客户端名%></div><div class="th" id="thMAC" style="width:10%"><%:MAC%></div><div class="th" id="thIP" style="width:17%"><%:IP%></div><div class="th" id="thTotal" style="width:9%"><%:总计流量%></div><div class="th" id="thFirstSeen" style="width:15%"><%:在线时间%></div></div>
$js_str
</div>
@ -997,7 +997,7 @@ function login_send(){
content="${content}${str_splitline}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${web_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
else
title="设备状态变化"
content="${content}${str_splitline}${str_title_start}${font_green} 登录信息${font_end}${str_title_end}${str_linefeed}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${web_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
content="${content}${str_splitline}${str_title_start}${font_green} 登录成功来源${font_end}${str_title_end}${str_linefeed}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${web_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
fi
fi
echo "`date "+%Y-%m-%d %H:%M:%S"` ${disturb_text}设备 ${login_ip} 通过 web ${web_login_mode} 登录了路由器 " >> ${logfile}
@ -1015,13 +1015,13 @@ function login_send(){
if [ ! -z "$ssh_logged" ] && [ "$ssh_logged" -eq "1" ]; then
if [ -z "$title" ]; then
title="${login_ip} 通过 SSH 登录了路由器"
content="${content}${str_splitline}${str_title_start}${font_green} 登录信息${font_end}${str_title_end}${str_linefeed}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${ssh_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
content="${content}${str_splitline}${str_title_start}${font_green} 登录成功来源${font_end}${str_title_end}${str_linefeed}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${ssh_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
elif ( echo "$title"|grep -q "登录了路由器" ); then
title="${login_ip} ${title}"
content="${content}${str_splitline}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${ssh_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
else
title="设备状态变化"
content="${content}${str_splitline}${str_title_start}${font_green} 登录信息${str_title_end}${str_linefeed}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${ssh_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
content="${content}${str_splitline}${str_title_start}${font_green} 登录成功来源${str_title_end}${str_linefeed}${str_tab}时间:${str_space}${str_space}${str_space}${str_space}${str_space}${ssh_login_time}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}${content_mode}"
fi
fi
echo "`date "+%Y-%m-%d %H:%M:%S"` 【info】设备 ${login_ip} 通过 SSH ${ssh_login_mode} 登录了路由器 " >> ${logfile}
@ -1038,13 +1038,13 @@ function login_send(){
if [ ! -z "$web_login_failed" ] && [ "$web_login_failed" -eq "1" ]; then
if [ -z "$title" ]; then
title="${login_ip} 通过 Web 频繁尝试登录"
content="${content}${str_splitline}${str_title_start}${font_red} 登录信息${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
content="${content}${str_splitline}${str_title_start}${font_red} 登录失败来源${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
elif ( echo "$title"|grep -q "频繁尝试登录" ); then
title="${login_ip} ${title}"
content="${content}${str_splitline}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
else
title="设备状态变化"
content="${content}${str_splitline}${str_title_start}${font_red} 登录信息${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
content="${content}${str_splitline}${str_title_start}${font_red} 登录失败来源${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
fi
fi
sed -i "/^${login_ip}$/d" ${dir}web_failed
@ -1063,13 +1063,13 @@ function login_send(){
if [ ! -z "$ssh_login_failed" ] && [ "$ssh_login_failed" -eq "1" ]; then
if [ -z "$title" ]; then
title="${login_ip} 通过 SSH 频繁尝试登录"
content="${content}${str_splitline}${str_title_start}${font_red} 登录信息${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
content="${content}${str_splitline}${str_title_start}${font_red} 登录失败来源${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
elif ( echo "$title"|grep -q "频繁尝试登录" ); then
title="${login_ip} ${title}"
content="${content}${str_splitline}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
else
title="设备状态变化"
content="${content}${str_splitline}${str_title_start}${font_red} 登录信息${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
content="${content}${str_splitline}${str_title_start}${font_red} 登录失败来源${font_end}${str_title_end}${str_linefeed}${str_tab}设备 IP ${str_space}${str_space}${str_space}${str_space}${login_ip}"
fi
fi
sed -i "/^${login_ip}$/d" ${dir}ssh_failed