update 2022-11-17 20:22:46
This commit is contained in:
parent
5be7b7324b
commit
7e8c3ecc7e
|
@ -147,7 +147,8 @@ function gen_outbound(node, tag, proxy_table)
|
|||
security = node.stream_security,
|
||||
xtlsSettings = (node.stream_security == "xtls") and {
|
||||
serverName = node.tls_serverName,
|
||||
allowInsecure = (node.tls_allowInsecure == "1") and true or false
|
||||
allowInsecure = (node.tls_allowInsecure == "1") and true or false,
|
||||
fingerprint = (node.type == "Xray" and node.fingerprint and node.fingerprint ~= "disable") and node.fingerprint or nil
|
||||
} or nil,
|
||||
tlsSettings = (node.stream_security == "tls") and {
|
||||
serverName = node.tls_serverName,
|
||||
|
@ -216,7 +217,7 @@ function gen_outbound(node, tag, proxy_table)
|
|||
level = 0,
|
||||
security = (node.protocol == "vmess") and node.security or nil,
|
||||
encryption = node.encryption or "none",
|
||||
flow = node.flow or nil
|
||||
flow = node.flow or (node.tls == '1' and node.xtls ~= '1' and node.tlsflow) and node.tlsflow or nil
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -226,7 +227,7 @@ function gen_outbound(node, tag, proxy_table)
|
|||
address = node.address,
|
||||
port = tonumber(node.port),
|
||||
method = node.method or nil,
|
||||
flow = node.flow or nil,
|
||||
flow = node.flow or (node.tls == '1' and node.xtls ~= '1' and node.tlsflow) and node.tlsflow or nil,
|
||||
ivCheck = (node.protocol == "shadowsocks") and node.iv_check == "1" or nil,
|
||||
uot = (node.protocol == "shadowsocks") and node.uot == "1" or nil,
|
||||
password = node.password or "",
|
||||
|
|
|
@ -511,6 +511,13 @@ xtls.default = 0
|
|||
xtls:depends({ type = "Xray", protocol = "vless", tls = true })
|
||||
xtls:depends({ type = "Xray", protocol = "trojan", tls = true })
|
||||
|
||||
tlsflow = s:option(Value, "tlsflow", translate("flow"))
|
||||
tlsflow.default = ""
|
||||
tlsflow:value("", translate("Disable"))
|
||||
tlsflow:value("xtls-rprx-vision")
|
||||
tlsflow:value("xtls-rprx-vision-udp443")
|
||||
tlsflow:depends({ type = "Xray", protocol = "vless", tls = true , xtls = false })
|
||||
|
||||
flow = s:option(Value, "flow", translate("flow"))
|
||||
flow.default = "xtls-rprx-direct"
|
||||
flow:value("xtls-rprx-origin")
|
||||
|
@ -530,6 +537,11 @@ alpn:value("http/1.1")
|
|||
alpn:depends({ type = "V2ray", tls = true })
|
||||
alpn:depends({ type = "Xray", tls = true })
|
||||
|
||||
-- minversion = s:option(Value, "minversion", translate("minversion"))
|
||||
-- minversion.default = "1.3"
|
||||
-- minversion:value("1.3")
|
||||
-- minversion:depends("tls", true)
|
||||
|
||||
-- [[ TLS部分 ]] --
|
||||
tls_sessionTicket = s:option(Flag, "tls_sessionTicket", translate("Session Ticket"))
|
||||
tls_sessionTicket.default = "0"
|
||||
|
@ -568,6 +580,7 @@ xray_fingerprint:value("safari")
|
|||
xray_fingerprint:value("randomized")
|
||||
xray_fingerprint.default = "disable"
|
||||
xray_fingerprint:depends({ type = "Xray", tls = true, xtls = false })
|
||||
xray_fingerprint:depends({ type = "Xray", tls = true, xtls = true })
|
||||
function xray_fingerprint.cfgvalue(self, section)
|
||||
return m:get(section, "fingerprint")
|
||||
end
|
||||
|
|
|
@ -14,7 +14,7 @@ function gen_config(user)
|
|||
for i = 1, #user.uuid do
|
||||
clients[i] = {
|
||||
id = user.uuid[i],
|
||||
flow = ("1" == user.xtls) and user.flow or nil
|
||||
flow = ("1" == user.xtls) and user.flow or ("1" == user.tls and "1" ~= user.xtls and user.tlsflow) and user.tlsflow or nil
|
||||
}
|
||||
end
|
||||
settings = {
|
||||
|
@ -57,7 +57,7 @@ function gen_config(user)
|
|||
local clients = {}
|
||||
for i = 1, #user.uuid do
|
||||
clients[i] = {
|
||||
flow = ("1" == user.xtls) and user.flow or nil,
|
||||
flow = ("1" == user.xtls) and user.flow or ("1" == user.tls and "1" ~= user.xtls and user.tlsflow) and user.tlsflow or nil,
|
||||
password = user.uuid[i],
|
||||
}
|
||||
end
|
||||
|
|
|
@ -392,6 +392,13 @@ xtls.default = 0
|
|||
xtls:depends({ type = "Xray", protocol = "vless", tls = true })
|
||||
xtls:depends({ type = "Xray", protocol = "trojan", tls = true })
|
||||
|
||||
tlsflow = s:option(Value, "tlsflow", translate("flow"))
|
||||
tlsflow.default = ""
|
||||
tlsflow:value("", translate("Disable"))
|
||||
tlsflow:value("xtls-rprx-vision")
|
||||
tlsflow:value("xtls-rprx-vision-udp443")
|
||||
tlsflow:depends({ type = "Xray", protocol = "vless", tls = true , xtls = false })
|
||||
|
||||
flow = s:option(Value, "flow", translate("flow"))
|
||||
flow.default = "xtls-rprx-direct"
|
||||
flow:value("xtls-rprx-origin")
|
||||
|
@ -406,6 +413,11 @@ alpn:value("http/1.1")
|
|||
alpn:depends({ type = "V2ray", tls = true })
|
||||
alpn:depends({ type = "Xray", tls = true })
|
||||
|
||||
-- minversion = s:option(Value, "minversion", translate("minversion"))
|
||||
-- minversion.default = "1.3"
|
||||
-- minversion:value("1.3")
|
||||
-- minversion:depends("tls", true)
|
||||
|
||||
-- [[ TLS部分 ]] --
|
||||
|
||||
tls_certificateFile = s:option(FileUpload, "tls_certificateFile", translate("Public key absolute path"), translate("as:") .. "/etc/ssl/fullchain.pem")
|
||||
|
|
|
@ -285,19 +285,30 @@ local has_xray = api.is_finded("xray")
|
|||
params += "&type=" + v_transport;
|
||||
|
||||
params += opt.query("encryption", "encryption");
|
||||
|
||||
if (opt.get("tls").checked) {
|
||||
var v_security = "tls";
|
||||
if (opt.get("xtls").checked) {
|
||||
v_security = "xtls";
|
||||
var v_security = "tls";
|
||||
var v_flow = "xtls-rprx-vision";
|
||||
if (opt.get("tlsflow").value) {
|
||||
v_flow = opt.get("tlsflow").value;
|
||||
}
|
||||
params += "&flow=" + v_flow;
|
||||
params += "&security=" + v_security;
|
||||
params += opt.query("sni", "tls_serverName");
|
||||
}
|
||||
|
||||
if (opt.get("xtls").checked) {
|
||||
var v_security = "xtls";
|
||||
var v_flow = "xtls-rprx-direct";
|
||||
if (opt.get("flow").value) {
|
||||
v_flow = opt.get("flow").value;
|
||||
}
|
||||
params += "&flow=" + v_flow;
|
||||
}
|
||||
params += "&security=" + v_security;
|
||||
params += opt.query("sni", "tls_serverName");
|
||||
params += "&security=" + v_security;
|
||||
params += opt.query("sni", "tls_serverName");
|
||||
}
|
||||
|
||||
|
||||
params += "#" + encodeURI(v_alias.value);
|
||||
if (params[0] == "&") {
|
||||
params = params.substring(1);
|
||||
|
@ -850,14 +861,22 @@ local has_xray = api.is_finded("xray")
|
|||
|
||||
opt.set('encryption', queryParam.encryption);
|
||||
if (queryParam.security) {
|
||||
if (queryParam.security == "tls" || queryParam.security == "xtls") {
|
||||
if (queryParam.security == "tls") {
|
||||
opt.set('tls', true);
|
||||
if (queryParam.security == "xtls") {
|
||||
opt.set('xtls', true);
|
||||
opt.set('flow', queryParam.flow || "xtls-rprx-direct");
|
||||
}
|
||||
opt.set('xtls',false);
|
||||
opt.set('tlsflow', queryParam.flow || '');
|
||||
opt.set('tls_serverName', queryParam.sni || '');
|
||||
opt.set('tls_allowInsecure', true);
|
||||
if (queryParam.allowinsecure === '0') {
|
||||
opt.set('tls_allowInsecure', false);
|
||||
}
|
||||
}
|
||||
|
||||
if (queryParam.security == "xtls") {
|
||||
opt.set('tls', true);
|
||||
opt.set('xtls',true);
|
||||
opt.set('flow', queryParam.flow || "xtls-rprx-direct");
|
||||
opt.set('tls_serverName', queryParam.sni || '');
|
||||
|
||||
opt.set('tls_allowInsecure', true);
|
||||
if (queryParam.allowinsecure === '0') {
|
||||
opt.set('tls_allowInsecure', false);
|
||||
|
|
|
@ -776,6 +776,8 @@ local function processData(szType, content, add_mode, add_from)
|
|||
if params.security == "xtls" then
|
||||
result.xtls = "1"
|
||||
result.flow = params.flow or "xtls-rprx-direct"
|
||||
else
|
||||
result.tlsflow = params.flow or nil
|
||||
end
|
||||
result.tls_serverName = (params.sni and params.sni ~= "") and params.sni or params.host
|
||||
end
|
||||
|
|
|
@ -0,0 +1,24 @@
|
|||
## API
|
||||
这里列出的接口都是 lua 实现的,对于 POST 请求都是提交表单( `multipart/form-data` 或者 `application/x-www-form-urlencoded` ),而不是 JSON,并且 POST 请求必须提供 `token` 参数用于防止 CSRF,`token` 的值可以从全局变量 `window.token` 取得。
|
||||
|
||||
1. 自动安装配置软件包
|
||||
```
|
||||
POST /cgi-bin/luci/admin/nas/quickstart/auto_setup
|
||||
token=xxx&packages=aria2&packages=qbittorrent
|
||||
|
||||
|
||||
{"success":0}
|
||||
{"success":1, "scope":"taskd", "error":"task already running"}
|
||||
```
|
||||
这是个异步接口,除非任务已经在运行,否则都会成功(success=0)。`packages` 是需要安装配置的软件包列表,与元数据的id对应
|
||||
|
||||
2. 获取安装配置结果
|
||||
```
|
||||
GET /cgi-bin/luci/admin/nas/quickstart/setup_result
|
||||
|
||||
|
||||
{"success":0, "result": {"ongoing": true, "packages": ["aria2", "qbittorrent"], "success":["aria2"], "failed":[]} }
|
||||
{"success":404, "scope":"taskd", "error":"task not found"}
|
||||
```
|
||||
用于在安装过程中或者安装完成时获取当前状态。
|
||||
安装过程中或者安装完成时,`success` 都是 0,`result.ongoing` 表示是否在安装过程中,`result.packages` 是提交的任务列表,`result.success` 是已成功的任务列表,`result.failed` 是已失败的任务列表
|
|
@ -9,7 +9,7 @@ LUCI_TITLE:=LuCI support for quickstart
|
|||
LUCI_DEPENDS:=+quickstart +luci-app-store
|
||||
LUCI_PKGARCH:=all
|
||||
|
||||
PKG_VERSION:=0.5.8-1
|
||||
PKG_VERSION:=0.5.9-1
|
||||
# PKG_RELEASE MUST be empty for luci.mk
|
||||
PKG_RELEASE:=
|
||||
|
||||
|
|
|
@ -13,6 +13,10 @@ function index()
|
|||
entry({"admin", "nas", "raid"}, call("quickstart_index", {index={"admin", "nas"}}), _("RAID"), 10).leaf = true
|
||||
entry({"admin", "nas", "smart"}, call("quickstart_index", {index={"admin", "nas"}}), _("S.M.A.R.T."), 11).leaf = true
|
||||
entry({"admin", "network", "interfaceconfig"}, call("quickstart_index", {index={"admin", "network"}}), _("NetworkPort"), 11).leaf = true
|
||||
|
||||
entry({"admin", "nas", "quickstart"}).dependent = false
|
||||
entry({"admin", "nas", "quickstart", "auto_setup"}, post("auto_setup"))
|
||||
entry({"admin", "nas", "quickstart", "setup_result"}, call("setup_result"))
|
||||
else
|
||||
entry({"admin", "quickstart"}, call("redirect_fallback")).leaf = true
|
||||
end
|
||||
|
@ -33,3 +37,116 @@ end
|
|||
function quickstart_dev(param)
|
||||
luci.template.render("quickstart/main_dev", {prefix=luci.dispatcher.build_url(unpack(param.index))})
|
||||
end
|
||||
|
||||
function auto_setup()
|
||||
local os = require "os"
|
||||
local fs = require "nixio.fs"
|
||||
local rshift = nixio.bit.rshift
|
||||
|
||||
-- json style
|
||||
-- local jsonc = require "luci.jsonc"
|
||||
-- local json_parse = jsonc.parse
|
||||
-- local req = json_parse(luci.http.content())
|
||||
-- local pkgs = ""
|
||||
-- for k, v in pairs(req.packages) do
|
||||
-- pkgs = pkgs .. " " .. luci.util.shellquote(v)
|
||||
-- end
|
||||
|
||||
-- form style
|
||||
local packages = luci.http.formvalue("packages")
|
||||
local pkgs = ""
|
||||
if type(packages) == "table" then
|
||||
if #packages > 0 then
|
||||
for k, v in pairs(packages) do
|
||||
pkgs = pkgs .. " " .. luci.util.shellquote(v)
|
||||
end
|
||||
end
|
||||
else
|
||||
if packages ~= nil and packages ~= "" then
|
||||
pkgs = luci.util.shellquote(packages)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
local ret
|
||||
if pkgs == "" then
|
||||
ret = {
|
||||
success = 1,
|
||||
scope = "params",
|
||||
error = "Parameter 'packages' undefined!",
|
||||
}
|
||||
else
|
||||
local cmd = "/usr/libexec/quickstart/auto_setup.sh " .. pkgs
|
||||
cmd = "/etc/init.d/tasks task_add auto_setup " .. luci.util.shellquote(cmd)
|
||||
local r = os.execute(cmd .. " >/var/log/auto_setup.stdout 2>/var/log/auto_setup.stderr")
|
||||
local e = fs.readfile("/var/log/auto_setup.stderr")
|
||||
local o = fs.readfile("/var/log/auto_setup.stdout")
|
||||
|
||||
fs.unlink("/var/log/auto_setup.stderr")
|
||||
fs.unlink("/var/log/auto_setup.stdout")
|
||||
e = e or ""
|
||||
if r == 256 and e == "" then
|
||||
e = "os.execute exit code 1"
|
||||
end
|
||||
r = rshift(r,8)
|
||||
ret = {
|
||||
success = r,
|
||||
scope = "taskd",
|
||||
error = e,
|
||||
detail = o,
|
||||
}
|
||||
end
|
||||
luci.http.prepare_content("application/json")
|
||||
luci.http.write_json(ret)
|
||||
end
|
||||
|
||||
function setup_result()
|
||||
local fs = require "nixio.fs"
|
||||
local taskd = require "luci.model.tasks"
|
||||
local packages = nil
|
||||
local success = nil
|
||||
local failed = nil
|
||||
local status = taskd.status("auto_setup")
|
||||
local ret = {
|
||||
}
|
||||
if status.running or status.exit_code ~= 404 then
|
||||
local item
|
||||
local po = fs.readfile("/var/log/auto_setup.input") or ""
|
||||
for item in po:gmatch("[^\n]+") do
|
||||
if packages then
|
||||
packages[#packages+1] = item
|
||||
else
|
||||
packages = {item}
|
||||
end
|
||||
end
|
||||
local so = fs.readfile("/var/log/auto_setup.success") or ""
|
||||
for item in so:gmatch("[^\n]+") do
|
||||
if success then
|
||||
success[#success+1] = item
|
||||
else
|
||||
success = {item}
|
||||
end
|
||||
end
|
||||
local fo = fs.readfile("/var/log/auto_setup.failed") or ""
|
||||
for item in fo:gmatch("[^\n]+") do
|
||||
if failed then
|
||||
failed[#failed+1] = item
|
||||
else
|
||||
failed = {item}
|
||||
end
|
||||
end
|
||||
ret.success = 0
|
||||
ret.result = {
|
||||
ongoing = status.running,
|
||||
packages = packages,
|
||||
success = success,
|
||||
failed = failed,
|
||||
}
|
||||
else
|
||||
ret.success = 404
|
||||
ret.scope = "taskd"
|
||||
ret.error = "task not found"
|
||||
end
|
||||
luci.http.prepare_content("application/json")
|
||||
luci.http.write_json(ret)
|
||||
end
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
-%>
|
||||
<script>
|
||||
(function(){
|
||||
window.token = "<%=token%>";
|
||||
var vue_prefix="<%=prefix%>";
|
||||
window.vue_base = vue_prefix + '/';
|
||||
window.quickstart_features = <%=jsonc.stringify(features)%>;
|
||||
|
|
|
@ -0,0 +1,61 @@
|
|||
#!/bin/sh
|
||||
|
||||
> /var/log/auto_setup.success
|
||||
> /var/log/auto_setup.failed
|
||||
> /var/log/auto_setup.input
|
||||
|
||||
save_input() {
|
||||
local pkg
|
||||
for pkg in $@; do
|
||||
echo "$pkg" >> /var/log/auto_setup.input
|
||||
done
|
||||
}
|
||||
save_input "$@"
|
||||
|
||||
. /lib/functions.sh
|
||||
|
||||
load_quickstart_cfg() {
|
||||
config_load quickstart || return $?
|
||||
|
||||
local main_dir conf_dir pub_dir dl_dir tmp_dir
|
||||
config_get main_dir "main" main_dir
|
||||
[ -z "$main_dir" ] && { echo "Home dir not configured!" >&2 ; return 1 ; }
|
||||
config_get conf_dir "main" conf_dir "$main_dir/Configs"
|
||||
config_get pub_dir "main" pub_dir "$main_dir/Public"
|
||||
config_get tmp_dir "main" tmp_dir "$main_dir/Caches"
|
||||
config_get dl_dir "main" dl_dir "$pub_dir/Downloads"
|
||||
|
||||
export ISTORE_CONF_DIR="$conf_dir"
|
||||
export ISTORE_DL_DIR="$dl_dir"
|
||||
export ISTORE_CACHE_DIR="$tmp_dir"
|
||||
export ISTORE_PUBLIC_DIR="$pub_dir"
|
||||
|
||||
mkdir -p "$ISTORE_CONF_DIR" "$ISTORE_DL_DIR" "$ISTORE_CACHE_DIR" "$ISTORE_PUBLIC_DIR"
|
||||
chmod 777 "$ISTORE_DL_DIR"
|
||||
}
|
||||
|
||||
auto_setup_app() {
|
||||
local pkg=$1
|
||||
is-opkg install "app-meta-$pkg" || return 1
|
||||
sh -c ". '/usr/libexec/istorea/$pkg.sh'"
|
||||
}
|
||||
|
||||
auto_setup_apps() {
|
||||
local pkg
|
||||
for pkg in $@; do
|
||||
echo "Setting up $pkg..."
|
||||
if auto_setup_app $pkg; then
|
||||
echo "Set up $pkg success"
|
||||
echo "$pkg" >> /var/log/auto_setup.success
|
||||
else
|
||||
echo "Set up $pkg failed"
|
||||
echo "$pkg" >> /var/log/auto_setup.failed
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
load_quickstart_cfg || exit $?
|
||||
|
||||
auto_setup_apps "$@"
|
||||
|
||||
[ ! -s /var/log/auto_setup.failed ]
|
|
@ -26,7 +26,8 @@ chinesesubfinder.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Downloads")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["Public"].."/Downloads")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_VERSION:=1.0.0-20221114
|
||||
PKG_VERSION:=1.0.0-20221117
|
||||
PKG_RELEASE:=
|
||||
|
||||
LUCI_TITLE:=LuCI support for Emby
|
||||
|
|
|
@ -24,7 +24,7 @@ o.rmempty = false
|
|||
|
||||
o = s:option(Value, "http_port", translate("HTTP Port").."<b>*</b>")
|
||||
o.default = "8096"
|
||||
o.datatype = "string"
|
||||
o.datatype = "port"
|
||||
o:depends("hostnet", 0)
|
||||
|
||||
o = s:option(Value, "image_name", translate("Image").."<b>*</b>")
|
||||
|
|
|
@ -26,7 +26,8 @@ emby.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Downloads")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["Public"].."/Downloads")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
|
|
@ -26,7 +26,8 @@ jellyfin.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Downloads")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["Public"].."/Downloads")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_VERSION:=1.0.0-20221116
|
||||
PKG_VERSION:=1.0.0-20221117
|
||||
PKG_RELEASE:=
|
||||
|
||||
LUCI_TITLE:=LuCI support for LANraragi
|
||||
|
|
|
@ -26,7 +26,7 @@ lanraragi.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
@ -40,7 +40,7 @@ lanraragi.find_paths = function(blocks, home_dirs, path_name)
|
|||
return
|
||||
else
|
||||
if path_name == "Public" then
|
||||
appname = "/Book"
|
||||
appname = "/Comics"
|
||||
end
|
||||
for _, val in pairs(blocks) do
|
||||
table.insert(configs, val .. "/" .. path_name .. appname)
|
||||
|
|
|
@ -26,7 +26,8 @@ nastools.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Downloads")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["Public"].."/Downloads")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_VERSION:=1.0.0-20221112
|
||||
PKG_VERSION:=1.0.0-20221117
|
||||
PKG_RELEASE:=
|
||||
|
||||
LUCI_TITLE:=LuCI support for Navidrome
|
||||
|
|
|
@ -45,7 +45,7 @@ o.default = default_path
|
|||
o = s:option(Value, "music_path", translate("Music path").."<b>*</b>")
|
||||
o.rmempty = false
|
||||
o.datatype = "string"
|
||||
local paths, default_path = navidrome_model.find_paths(blocks, home, "Downloads")
|
||||
local paths, default_path = navidrome_model.find_paths(blocks, home, "Public")
|
||||
for _, val in pairs(paths) do
|
||||
o:value(val, val)
|
||||
end
|
||||
|
|
|
@ -26,7 +26,7 @@ navidrome.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Downloads")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
@ -39,7 +39,7 @@ navidrome.find_paths = function(blocks, home_dirs, path_name)
|
|||
if #blocks == 0 then
|
||||
return
|
||||
else
|
||||
if path_name == "Downloads" then
|
||||
if path_name == "Public" then
|
||||
appname = "/Music"
|
||||
end
|
||||
for _, val in pairs(blocks) do
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_VERSION:=1.0.0-20221116
|
||||
PKG_VERSION:=1.0.0-20221117
|
||||
PKG_RELEASE:=
|
||||
|
||||
LUCI_TITLE:=LuCI support for PhotoPrism
|
||||
|
|
|
@ -26,7 +26,7 @@ photoprism.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_VERSION:=1.0.0-20221106
|
||||
PKG_VERSION:=1.0.0-20221117
|
||||
PKG_RELEASE:=
|
||||
|
||||
LUCI_TITLE:=LuCI support for Plex
|
||||
|
|
|
@ -26,7 +26,6 @@ o = s:option(Value, "claim_token", translate("Plex Claim"))
|
|||
o.datatype = "string"
|
||||
|
||||
o = s:option(Value, "port", translate("Port").."<b>*</b>")
|
||||
o.rmempty = false
|
||||
o.default = "32400"
|
||||
o.datatype = "port"
|
||||
o:depends("hostnet", 0)
|
||||
|
|
|
@ -26,7 +26,8 @@ plex.home = function()
|
|||
local home_dirs = {}
|
||||
home_dirs["main_dir"] = uci:get_first("quickstart", "main", "main_dir", "/root")
|
||||
home_dirs["Configs"] = uci:get_first("quickstart", "main", "conf_dir", home_dirs["main_dir"].."/Configs")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["main_dir"].."/Downloads")
|
||||
home_dirs["Public"] = uci:get_first("quickstart", "main", "pub_dir", home_dirs["main_dir"].."/Public")
|
||||
home_dirs["Downloads"] = uci:get_first("quickstart", "main", "dl_dir", home_dirs["Public"].."/Downloads")
|
||||
home_dirs["Caches"] = uci:get_first("quickstart", "main", "tmp_dir", home_dirs["main_dir"].."/Caches")
|
||||
return home_dirs
|
||||
end
|
||||
|
|
|
@ -10,11 +10,11 @@ include $(TOPDIR)/rules.mk
|
|||
PKG_ARCH_quickstart:=$(ARCH)
|
||||
|
||||
PKG_NAME:=quickstart
|
||||
PKG_VERSION:=0.6.0
|
||||
PKG_RELEASE:=2
|
||||
PKG_VERSION:=0.6.1
|
||||
PKG_RELEASE:=1
|
||||
PKG_SOURCE:=$(PKG_NAME)-binary-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://fw.koolcenter.com/binary/quickstart/
|
||||
PKG_HASH:=0893c8d58cb639946f33b2dd5841729b613eb89651c11bd40294d9235323784c
|
||||
PKG_HASH:=c57176ee1450162d06ca6b92c11055852f585ae0dfa8bbca10de5ed8431ea405
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-binary-$(PKG_VERSION)
|
||||
|
||||
|
|
|
@ -1,54 +0,0 @@
|
|||
#
|
||||
# Copyright (C) 2014 OpenWrt-dist
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
|
||||
PKG_NAME:=redsocks2
|
||||
PKG_VERSION:=0.67
|
||||
PKG_RELEASE:=4
|
||||
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=https://github.com/semigodking/redsocks.git
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_SOURCE_VERSION:=d94c245ea47859cda5b4b7373308589206b97bdc
|
||||
PKG_MIRROR_HASH:=938f859d1b55a91aa5cbcda3ddff1d04ccab292f784b0434060c73acab12c457
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
|
||||
PKG_MAINTAINER:=semigodking <semigodking@gmail.com>
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)/$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/redsocks2
|
||||
SECTION:=net
|
||||
CATEGORY:=Network
|
||||
SUBMENU:=Web Servers/Proxies
|
||||
TITLE:=Redirect any TCP connection to a SOCKS or HTTPS proxy server
|
||||
URL:=https://github.com/semigodking/redsocks
|
||||
DEPENDS:=+libevent2 +libopenssl
|
||||
endef
|
||||
|
||||
define Package/redsocks2/description
|
||||
This is a modified version of original redsocks. \
|
||||
The name is changed to be REDSOCKS2 since this release to distinguish with original redsocks. \
|
||||
This variant is useful for anti-GFW (Great Fire Wall).
|
||||
endef
|
||||
|
||||
define Package/redsocks2/conffiles
|
||||
/etc/config/redsocks2
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
$(call Build/Compile/Default,DISABLE_SHADOWSOCKS=true)
|
||||
endef
|
||||
|
||||
define Package/redsocks2/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/redsocks2 $(1)/usr/sbin
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,redsocks2))
|
|
@ -4,36 +4,37 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
ifeq ($(ARCH),x86_64)
|
||||
PKG_ARCH_VERYSYNC:=amd64
|
||||
endif
|
||||
ifeq ($(ARCH),mipsel)
|
||||
PKG_ARCH_VERYSYNC:=mipsle
|
||||
endif
|
||||
ifeq ($(ARCH),mips)
|
||||
PKG_ARCH_VERYSYNC:=mips
|
||||
endif
|
||||
ifeq ($(ARCH),i386)
|
||||
PKG_ARCH_VERYSYNC:=386
|
||||
endif
|
||||
ifeq ($(ARCH),arm)
|
||||
PKG_ARCH_VERYSYNC:=arm
|
||||
endif
|
||||
ifeq ($(ARCH),aarch64)
|
||||
PKG_ARCH_VERYSYNC:=arm64
|
||||
endif
|
||||
ifeq ($(ARCH),powerpc64)
|
||||
PKG_ARCH_VERYSYNC:=ppc64
|
||||
PKG_ARCH_VERYSYNC:=arm64
|
||||
PKG_HASH_VERYSYNC:=113b1098434c9657e51d95a86f70436ff55db291cca1094bc65e911642424367
|
||||
else ifeq ($(ARCH),arm)
|
||||
PKG_ARCH_VERYSYNC:=arm
|
||||
PKG_HASH_VERYSYNC:=6eb2a8e41dcdaacfecc20c13ef6b7805176dad6a410d38bf65a962bc0f7f8554
|
||||
else ifeq ($(ARCH),i386)
|
||||
PKG_ARCH_VERYSYNC:=386
|
||||
PKG_HASH_VERYSYNC:=d84b71cc7ef0db95bf0f6dc3d38884b3856cc36ae1ac1f430c35cdd033cc7c16
|
||||
else ifeq ($(ARCH),mips)
|
||||
PKG_ARCH_VERYSYNC:=mips
|
||||
PKG_HASH_VERYSYNC:=54d8fe303e3b51ae5078fe74e69ab64d102334e55ee257d9eec7aef13a21d911
|
||||
else ifeq ($(ARCH),mipsel)
|
||||
PKG_ARCH_VERYSYNC:=mipsle
|
||||
PKG_HASH_VERYSYNC:=7edc4eae4a1941d8a52fce2506d599af6f207498a3d8cabe819f023d0df15e2f
|
||||
else ifeq ($(ARCH),powerpc64)
|
||||
PKG_ARCH_VERYSYNC:=ppc64
|
||||
PKG_HASH_VERYSYNC:=c89e670b31123b240fc5e4be15cb7e836e8584b5a955efea5fca5b4f9d009ea1
|
||||
else ifeq ($(ARCH),x86_64)
|
||||
PKG_ARCH_VERYSYNC:=amd64
|
||||
PKG_HASH_VERYSYNC:=6214cd485bfc40a8c53a3c53e900a0fa2e629d5137345f3ad2195bd9e0f47fba
|
||||
endif
|
||||
|
||||
PKG_NAME:=verysync
|
||||
PKG_VERSION:=2.13.2
|
||||
PKG_VERSION:=2.14.0
|
||||
PKG_RELEASE:=$(AUTORELEASE)
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-linux-$(PKG_ARCH_VERYSYNC)-v$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=http://dl.verysync.com/releases/v$(PKG_VERSION)/ \
|
||||
http://dl-cn.verysync.com/releases/v$(PKG_VERSION)/
|
||||
PKG_HASH:=skip
|
||||
PKG_HASH:=$(PKG_HASH_VERYSYNC)
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-linux-$(PKG_ARCH_VERYSYNC)-v$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
@ -43,6 +44,7 @@ define Package/verysync
|
|||
CATEGORY:=Network
|
||||
TITLE:=A efficient data transmission tool
|
||||
URL:=http://www.verysync.com
|
||||
DEPENDS:=@(aarch64||arm||i386||mips||mipsel||powerpc64||x86_64)
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
|
|
Loading…
Reference in New Issue