mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-16 04:13:31 +00:00
luci-app-ssr-plus: add custom Netflix IP Url (#3867)
This commit is contained in:
parent
d1bcf6d42c
commit
44e8a84cbc
@ -117,13 +117,14 @@ elseif set == "ip_data" then
|
||||
end
|
||||
luci.sys.exec("rm -f /tmp/china_ssr.txt ")
|
||||
elseif set == "nfip_data" then
|
||||
refresh_cmd="wget-ssl --no-check-certificate -O - https://raw.githubusercontent.com/QiuSimons/Netflix_IP/master/NF_only.txt > /tmp/netflixip.list"
|
||||
refresh_cmd="wget-ssl --no-check-certificate -O - ".. luci.model.uci.cursor():get_first('shadowsocksr', 'global', 'nfip_url','https://raw.githubusercontent.com/QiuSimons/Netflix_IP/master/NF_only.txt') .." > /tmp/netflixip.list"
|
||||
sret=luci.sys.call(refresh_cmd)
|
||||
icount = luci.sys.exec("cat /tmp/netflixip.list | wc -l")
|
||||
if sret== 0 and tonumber(icount)>1 then
|
||||
oldcount=luci.sys.exec("cat /etc/config/netflixip.list | wc -l")
|
||||
if tonumber(icount) ~= tonumber(oldcount) then
|
||||
luci.sys.exec("cp -f /tmp/netflixip.list /etc/config/netflixip.list")
|
||||
luci.sys.exec("/etc/init.d/shadowsocksr restart &")
|
||||
retstring=tostring(tonumber(icount))
|
||||
else
|
||||
retstring ="0"
|
||||
|
@ -42,6 +42,14 @@ o.default = "https://gitee.com/privacy-protection-tools/anti-ad/raw/master/anti-
|
||||
o:depends("adblock", "1")
|
||||
o.description = translate("Support AdGuardHome and DNSMASQ format list")
|
||||
|
||||
o = s:option(Flag, "netflix", translate("Enable Custom Netflix IP Url"))
|
||||
o.rmempty = false
|
||||
|
||||
o = s:option(Value, "nfip_url", translate("nfip_url"))
|
||||
o.default = "https://raw.githubusercontent.com/QiuSimons/Netflix_IP/master/NF_only.txt"
|
||||
o:depends("netflix", "1")
|
||||
o.description = translate("Customize Netflix IP Url")
|
||||
|
||||
-- [[ SOCKS Proxy ]]--
|
||||
if nixio.fs.access("/usr/bin/microsocks") then
|
||||
s = m:section(TypedSection, "socks5_proxy", translate("SOCKS5 Proxy Server Settings"))
|
||||
|
@ -334,6 +334,15 @@ msgstr "启用广告屏蔽"
|
||||
msgid "adblock_url"
|
||||
msgstr "广告屏蔽订阅"
|
||||
|
||||
msgid "Enable Custom Netflix IP Url"
|
||||
msgstr "启用自定义Netflix IP更新URL"
|
||||
|
||||
msgid "nfip_url"
|
||||
msgstr "Netflix IP更新URL"
|
||||
|
||||
msgid "Customize Netflix IP Url"
|
||||
msgstr "自定义Netflix IP更新URL(默认项目地址:https://github.com/QiuSimons/Netflix_IP)"
|
||||
|
||||
msgid "Enable Process Deamon"
|
||||
msgstr "启用进程自动守护"
|
||||
|
||||
|
@ -14,6 +14,7 @@ config global
|
||||
option adblock_url 'https://gitee.com/privacy-protection-tools/anti-ad/raw/master/anti-ad-for-dnsmasq.conf'
|
||||
option chnroute '0'
|
||||
option chnroute_url 'https://ispip.clang.cn/all_cn.txt'
|
||||
option nfip_url 'https://raw.githubusercontent.com/QiuSimons/Netflix_IP/master/NF_only.txt'
|
||||
option netflix_server 'same'
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user