1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

Update shadowsocks luci interface

This commit is contained in:
Ycarus (Yannick Chabanois) 2019-06-17 18:30:39 +02:00
parent 69275038c5
commit 95288f3b1d
14 changed files with 982 additions and 676 deletions

View file

@ -545,15 +545,11 @@ function settings_add()
local obfs = luci.http.formvalue("obfs") or "0"
local obfs_plugin = luci.http.formvalue("obfs_plugin") or "v2ray"
local obfs_type = luci.http.formvalue("obfs_type") or "http"
ucic:foreach("shadowsocks-libev", "ss_redir", function (section)
ucic:foreach("shadowsocks-libev", "server", function (section)
ucic:set("shadowsocks-libev",section[".name"],"obfs",obfs)
ucic:set("shadowsocks-libev",section[".name"],"obfs_plugin",obfs_plugin)
ucic:set("shadowsocks-libev",section[".name"],"obfs_type",obfs_type)
end)
ucic:set("shadowsocks-libev","tracker","obfs",obfs)
ucic:set("shadowsocks-libev","tracker","obfs_plugin",obfs_plugin)
ucic:set("shadowsocks-libev","tracker","obfs_type",obfs_type)
ucic:save("shadowsocks-libev")
ucic:commit("shadowsocks-libev")