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

Force check of backup when new VPS is created, fix reset of SS encryption #https://github.com/Ysurac/openmptcprouter/issues/316

This commit is contained in:
Ycarus 2019-01-14 17:26:36 +01:00
parent 5b10fe3bd5
commit 0e2a8e15d9
2 changed files with 3 additions and 3 deletions

View file

@ -355,8 +355,8 @@ function wizard_add()
local shadowsocks_disable = luci.http.formvalue("disableshadowsocks") or "0" local shadowsocks_disable = luci.http.formvalue("disableshadowsocks") or "0"
if shadowsocks_key ~= "" then if shadowsocks_key ~= "" then
ucic:set("shadowsocks-libev","sss0","key",shadowsocks_key) ucic:set("shadowsocks-libev","sss0","key",shadowsocks_key)
ucic:set("shadowsocks-libev","sss0","method","chacha20") --ucic:set("shadowsocks-libev","sss0","method","chacha20")
ucic:set("shadowsocks-libev","sss0","server_port","65101") --ucic:set("shadowsocks-libev","sss0","server_port","65101")
ucic:set("shadowsocks-libev","sss0","disabled",shadowsocks_disable) ucic:set("shadowsocks-libev","sss0","disabled",shadowsocks_disable)
ucic:save("shadowsocks-libev") ucic:save("shadowsocks-libev")
ucic:commit("shadowsocks-libev") ucic:commit("shadowsocks-libev")

View file

@ -90,7 +90,7 @@ end
<div class="cbi-value"> <div class="cbi-value">
<label class="cbi-value-title"><%:Set server as backup%></label> <label class="cbi-value-title"><%:Set server as backup%></label>
<div class="cbi-value-field"> <div class="cbi-value-field">
<input class="cbi-input-checkbox" type="checkbox" name="<%=servername%>.backup" value="1" <% if uci:get("openmptcprouter",servername,"backup") == "1" then %>checked<% end %>/> <input class="cbi-input-checkbox" type="checkbox" name="<%=servername%>.backup" value="1" <% if uci:get("openmptcprouter",servername,"backup") == "1" or uci:get("openmptcprouter",servername,"backup") == "" then %>checked<% end %>/>
</div> </div>
</div> </div>
<% <%