mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-10-31 22:15:13 +08:00
🏅 Sync 2026-03-17 23:49:29
This commit is contained in:
1 parent
cb0fc3c571
commit
4e0eb61db3
6 files changed
+55
-53
No files matched your search
@@ -11,8 +11,8 @@ PKG_ARCH_ISTOREENHANCE:=$(ARCH)
|
|||||||
|
|
||||||
PKG_NAME:=istoreenhance
|
PKG_NAME:=istoreenhance
|
||||||
# use PKG_SOURCE_DATE instead of PKG_VERSION for compitable
|
# use PKG_SOURCE_DATE instead of PKG_VERSION for compitable
|
||||||
PKG_SOURCE_DATE:=0.7.3
|
PKG_SOURCE_DATE:=0.7.5
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=3
|
||||||
ARCH_HEXCODE:=
|
ARCH_HEXCODE:=
|
||||||
ifeq ($(ARCH),x86_64)
|
ifeq ($(ARCH),x86_64)
|
||||||
ARCH_HEXCODE=8664
|
ARCH_HEXCODE=8664
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_VERSION:=0.1.0
|
PKG_VERSION:=0.1.0
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
|
|
||||||
LUCI_TITLE:=LuCI support for OpenClaw Launcher
|
LUCI_TITLE:=LuCI support for OpenClaw Launcher
|
||||||
LUCI_PKGARCH:=all
|
LUCI_PKGARCH:=all
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ config openclawmgr 'main'
|
|||||||
option token ''
|
option token ''
|
||||||
option allow_insecure_auth '0'
|
option allow_insecure_auth '0'
|
||||||
option disable_device_auth '0'
|
option disable_device_auth '0'
|
||||||
option node_version '22.16.0'
|
|
||||||
option install_accelerated '1'
|
option install_accelerated '1'
|
||||||
option default_agent 'anthropic'
|
option default_agent 'anthropic'
|
||||||
option default_model ''
|
option default_model ''
|
||||||
|
|||||||
@@ -12,7 +12,6 @@ fi
|
|||||||
[ -n "$(uci -q get openclawmgr.main.enabled 2>/dev/null)" ] || uci -q set openclawmgr.main.enabled='0'
|
[ -n "$(uci -q get openclawmgr.main.enabled 2>/dev/null)" ] || uci -q set openclawmgr.main.enabled='0'
|
||||||
[ -n "$(uci -q get openclawmgr.main.port 2>/dev/null)" ] || uci -q set openclawmgr.main.port='18789'
|
[ -n "$(uci -q get openclawmgr.main.port 2>/dev/null)" ] || uci -q set openclawmgr.main.port='18789'
|
||||||
[ -n "$(uci -q get openclawmgr.main.bind 2>/dev/null)" ] || uci -q set openclawmgr.main.bind='lan'
|
[ -n "$(uci -q get openclawmgr.main.bind 2>/dev/null)" ] || uci -q set openclawmgr.main.bind='lan'
|
||||||
[ -n "$(uci -q get openclawmgr.main.node_version 2>/dev/null)" ] || uci -q set openclawmgr.main.node_version='22.16.0'
|
|
||||||
[ -n "$(uci -q get openclawmgr.main.install_accelerated 2>/dev/null)" ] || uci -q set openclawmgr.main.install_accelerated='1'
|
[ -n "$(uci -q get openclawmgr.main.install_accelerated 2>/dev/null)" ] || uci -q set openclawmgr.main.install_accelerated='1'
|
||||||
[ -n "$(uci -q get openclawmgr.main.token 2>/dev/null)" ] || uci -q set openclawmgr.main.token=''
|
[ -n "$(uci -q get openclawmgr.main.token 2>/dev/null)" ] || uci -q set openclawmgr.main.token=''
|
||||||
[ -n "$(uci -q get openclawmgr.main.allow_insecure_auth 2>/dev/null)" ] || uci -q set openclawmgr.main.allow_insecure_auth='0'
|
[ -n "$(uci -q get openclawmgr.main.allow_insecure_auth 2>/dev/null)" ] || uci -q set openclawmgr.main.allow_insecure_auth='0'
|
||||||
|
|||||||
@@ -244,11 +244,12 @@ ks_admin_port() {
|
|||||||
|
|
||||||
download() {
|
download() {
|
||||||
local url="$1" out="$2"
|
local url="$1" out="$2"
|
||||||
local ap admin_path resp err tmp rc ks_enabled
|
local ap admin_path resp err tmp rc ks_enabled resp_file http_code
|
||||||
|
|
||||||
tmp="/tmp/${APP}-curl.err"
|
tmp="/tmp/${APP}-curl.err"
|
||||||
err="/tmp/${APP}-curl.err2"
|
err="/tmp/${APP}-curl.err2"
|
||||||
rm -f "$tmp" "$err" 2>/dev/null || true
|
resp_file="/tmp/${APP}-ks-remap.json"
|
||||||
|
rm -f "$tmp" "$err" "$resp_file" 2>/dev/null || true
|
||||||
|
|
||||||
if [ "${INSTALL_ACCELERATED:-1}" != "1" ]; then
|
if [ "${INSTALL_ACCELERATED:-1}" != "1" ]; then
|
||||||
write_installer_log "KSpeeder not used: accelerated install is disabled"
|
write_installer_log "KSpeeder not used: accelerated install is disabled"
|
||||||
@@ -260,9 +261,11 @@ download() {
|
|||||||
write_installer_log "KSpeeder not used: iStoreEnhance process is not running"
|
write_installer_log "KSpeeder not used: iStoreEnhance process is not running"
|
||||||
else
|
else
|
||||||
ap="$(uci -q get istoreenhance.@istoreenhance[0].adminport 2>/dev/null || echo 5003)"
|
ap="$(uci -q get istoreenhance.@istoreenhance[0].adminport 2>/dev/null || echo 5003)"
|
||||||
resp="$(curl -fsS --connect-timeout 2 --max-time 5 -G \
|
http_code="$(curl -sS --connect-timeout 2 --max-time 5 -G \
|
||||||
--data-urlencode "url=${url}" \
|
--data-urlencode "url=${url}" \
|
||||||
"http://127.0.0.1:${ap}/api/domainfold/remap" 2>"$tmp" || true)"
|
-o "$resp_file" -w "%{http_code}" \
|
||||||
|
"http://127.0.0.1:${ap}/api/domainfold/remap" 2>"$tmp" || echo 000)"
|
||||||
|
resp="$(cat "$resp_file" 2>/dev/null || true)"
|
||||||
admin_path="$(printf "%s" "$resp" | jsonfilter -e '@.admin_path' 2>/dev/null || true)"
|
admin_path="$(printf "%s" "$resp" | jsonfilter -e '@.admin_path' 2>/dev/null || true)"
|
||||||
if [ -n "$admin_path" ] && echo "$admin_path" | grep -q '^/'; then
|
if [ -n "$admin_path" ] && echo "$admin_path" | grep -q '^/'; then
|
||||||
if download_with_progress "http://127.0.0.1:${ap}${admin_path}" "$out" "$err" "Downloading via KSpeeder"; then
|
if download_with_progress "http://127.0.0.1:${ap}${admin_path}" "$out" "$err" "Downloading via KSpeeder"; then
|
||||||
@@ -272,10 +275,14 @@ download() {
|
|||||||
write_installer_log "Download via KSpeeder failed (rc=$rc): ${url}"
|
write_installer_log "Download via KSpeeder failed (rc=$rc): ${url}"
|
||||||
tail -n 5 "$err" 2>/dev/null | while IFS= read -r ln; do write_installer_log "$ln"; done
|
tail -n 5 "$err" 2>/dev/null | while IFS= read -r ln; do write_installer_log "$ln"; done
|
||||||
else
|
else
|
||||||
local e
|
local e brief
|
||||||
e="$(printf "%s" "$resp" | jsonfilter -e '@.error' 2>/dev/null || true)"
|
e="$(printf "%s" "$resp" | jsonfilter -e '@.error' 2>/dev/null || true)"
|
||||||
if [ -n "$e" ]; then
|
if [ -n "$e" ]; then
|
||||||
write_installer_log "KSpeeder remap failed: $e"
|
write_installer_log "KSpeeder remap failed (http=${http_code}): $e"
|
||||||
|
elif [ -n "$http_code" ] && [ "$http_code" != "000" ] && [ "$http_code" != "200" ]; then
|
||||||
|
brief="$(printf "%s" "$resp" | tr '\n' ' ' | sed 's/[[:space:]]\\+/ /g' | cut -c1-200)"
|
||||||
|
[ -n "$brief" ] || brief="(empty response)"
|
||||||
|
write_installer_log "KSpeeder not used: remap http=${http_code}: ${brief}"
|
||||||
elif [ -s "$tmp" ]; then
|
elif [ -s "$tmp" ]; then
|
||||||
write_installer_log "KSpeeder not used: remap request failed on 127.0.0.1:${ap}"
|
write_installer_log "KSpeeder not used: remap request failed on 127.0.0.1:${ap}"
|
||||||
tail -n 3 "$tmp" 2>/dev/null | while IFS= read -r ln; do write_installer_log "$ln"; done
|
tail -n 3 "$tmp" 2>/dev/null | while IFS= read -r ln; do write_installer_log "$ln"; done
|
||||||
@@ -612,29 +619,24 @@ cached_node_archive_ok() {
|
|||||||
tar -tJf "$archive" >/dev/null 2>&1
|
tar -tJf "$archive" >/dev/null 2>&1
|
||||||
}
|
}
|
||||||
|
|
||||||
install_node() {
|
install_node() {
|
||||||
local arch libc url tmp
|
local arch libc url tmp
|
||||||
arch="$(detect_arch)"
|
arch="$(detect_arch)"
|
||||||
[ "$arch" != "unsupported" ] || { write_installer_log "Unsupported arch"; return 1; }
|
[ "$arch" != "unsupported" ] || { write_installer_log "Unsupported arch"; return 1; }
|
||||||
|
|
||||||
if is_musl; then
|
if is_musl; then
|
||||||
libc="musl"
|
libc="musl"
|
||||||
else
|
else
|
||||||
libc="glibc"
|
libc="glibc"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$libc" = "musl" ] && [ "$arch" = "linux-x64" ]; then
|
# OpenWrt/iStoreOS runs on musl; use musl builds by default.
|
||||||
url="https://unofficial-builds.nodejs.org/download/release/v${NODE_VERSION}/node-v${NODE_VERSION}-${arch}-musl.tar.xz"
|
url="https://unofficial-builds.nodejs.org/download/release/v${NODE_VERSION}/node-v${NODE_VERSION}-${arch}-musl.tar.xz"
|
||||||
elif [ "$libc" = "musl" ] && [ "$arch" = "linux-arm64" ]; then
|
|
||||||
url="https://unofficial-builds.nodejs.org/download/release/v${NODE_VERSION}/node-v${NODE_VERSION}-${arch}-musl.tar.xz"
|
|
||||||
else
|
|
||||||
url="https://nodejs.org/dist/v${NODE_VERSION}/node-v${NODE_VERSION}-${arch}.tar.xz"
|
|
||||||
fi
|
|
||||||
|
|
||||||
if have_local_node_runtime; then
|
if have_local_node_runtime; then
|
||||||
write_installer_log "Using existing Node.js runtime: $($NODE_BIN --version 2>/dev/null || echo unknown)"
|
write_installer_log "Using existing Node.js runtime: $($NODE_BIN --version 2>/dev/null || echo unknown)"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -x "$NODE_BIN" ] || [ -x "$NPM_BIN" ]; then
|
if [ -x "$NODE_BIN" ] || [ -x "$NPM_BIN" ]; then
|
||||||
write_installer_log "Node.js runtime under $NODE_DIR is incomplete; reinstalling bundled Node.js"
|
write_installer_log "Node.js runtime under $NODE_DIR is incomplete; reinstalling bundled Node.js"
|
||||||
@@ -807,15 +809,18 @@ install_openclaw() {
|
|||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
do_install() {
|
do_install() {
|
||||||
acquire_lock
|
acquire_lock
|
||||||
write_installer_log "== install begin =="
|
write_installer_log "== install begin =="
|
||||||
ensure_dirs
|
ensure_dirs
|
||||||
if have_openclaw_runtime; then
|
# Node version is bundled/managed by installer code; do not allow UCI override.
|
||||||
write_installer_log "OpenClaw is already installed: $(openclaw_version || echo unknown)"
|
uci -q delete "${UCI_NS}.main.node_version" >/dev/null 2>&1 || true
|
||||||
write_installer_log "Skip install. Use restart/apply config if you only need to refresh configuration."
|
uci -q commit "$UCI_NS" >/dev/null 2>&1 || true
|
||||||
return 0
|
if have_openclaw_runtime; then
|
||||||
fi
|
write_installer_log "OpenClaw is already installed: $(openclaw_version || echo unknown)"
|
||||||
|
write_installer_log "Skip install. Use restart/apply config if you only need to refresh configuration."
|
||||||
|
return 0
|
||||||
|
fi
|
||||||
if ! has_default_route; then
|
if ! has_default_route; then
|
||||||
write_installer_log "Install requires internet access, but no default gateway is configured."
|
write_installer_log "Install requires internet access, but no default gateway is configured."
|
||||||
write_installer_log "Fix: configure WAN or add a default route, then retry Install."
|
write_installer_log "Fix: configure WAN or add a default route, then retry Install."
|
||||||
@@ -1047,13 +1052,12 @@ diag_poll() {
|
|||||||
ACTION="${1:-help}"
|
ACTION="${1:-help}"
|
||||||
shift 1 || true
|
shift 1 || true
|
||||||
|
|
||||||
BASE_DIR="$(uci_get base_dir)"
|
BASE_DIR="$(uci_get base_dir)"
|
||||||
PORT="$(uci_get port)"
|
PORT="$(uci_get port)"
|
||||||
BIND="$(uci_get bind)"
|
BIND="$(uci_get bind)"
|
||||||
NODE_VERSION="$(uci_get node_version)"
|
TOKEN="$(uci_get token)"
|
||||||
TOKEN="$(uci_get token)"
|
ALLOW_INSECURE_AUTH="$(uci_get allow_insecure_auth)"
|
||||||
ALLOW_INSECURE_AUTH="$(uci_get allow_insecure_auth)"
|
DISABLE_DEVICE_AUTH="$(uci_get disable_device_auth)"
|
||||||
DISABLE_DEVICE_AUTH="$(uci_get disable_device_auth)"
|
|
||||||
ALLOWED_ORIGINS="$(uci_get_list allowed_origins)"
|
ALLOWED_ORIGINS="$(uci_get_list allowed_origins)"
|
||||||
DEFAULT_AGENT="$(uci_get default_agent)"
|
DEFAULT_AGENT="$(uci_get default_agent)"
|
||||||
DEFAULT_MODEL="$(uci_get default_model)"
|
DEFAULT_MODEL="$(uci_get default_model)"
|
||||||
@@ -1061,10 +1065,10 @@ INSTALL_ACCELERATED="$(uci_get install_accelerated)"
|
|||||||
PROVIDER_API_KEY="$(uci_get provider_api_key)"
|
PROVIDER_API_KEY="$(uci_get provider_api_key)"
|
||||||
PROVIDER_BASE_URL="$(uci_get provider_base_url)"
|
PROVIDER_BASE_URL="$(uci_get provider_base_url)"
|
||||||
|
|
||||||
[ -n "$BASE_DIR" ] || BASE_DIR="/opt/openclawmgr"
|
[ -n "$BASE_DIR" ] || BASE_DIR="/opt/openclawmgr"
|
||||||
[ -n "$PORT" ] || PORT="18789"
|
[ -n "$PORT" ] || PORT="18789"
|
||||||
[ -n "$BIND" ] || BIND="lan"
|
[ -n "$BIND" ] || BIND="lan"
|
||||||
[ -n "$NODE_VERSION" ] || NODE_VERSION="22.16.0"
|
NODE_VERSION="24.14.0"
|
||||||
[ -n "$ALLOW_INSECURE_AUTH" ] || ALLOW_INSECURE_AUTH="0"
|
[ -n "$ALLOW_INSECURE_AUTH" ] || ALLOW_INSECURE_AUTH="0"
|
||||||
[ -n "$DISABLE_DEVICE_AUTH" ] || DISABLE_DEVICE_AUTH="0"
|
[ -n "$DISABLE_DEVICE_AUTH" ] || DISABLE_DEVICE_AUTH="0"
|
||||||
[ -n "$DEFAULT_AGENT" ] || DEFAULT_AGENT="anthropic"
|
[ -n "$DEFAULT_AGENT" ] || DEFAULT_AGENT="anthropic"
|
||||||
|
|||||||
+3
-3
@@ -1,8 +1,8 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=mtproxy
|
PKG_NAME:=mtproxy
|
||||||
PKG_VERSION:=3.0.11
|
PKG_VERSION:=3.0.12
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=3
|
||||||
|
|
||||||
PKG_MAINTAINER:=Kosntantine Shevlakov <shevlakov@132lan.ru>
|
PKG_MAINTAINER:=Kosntantine Shevlakov <shevlakov@132lan.ru>
|
||||||
PKG_LICENSE:=GPLv2
|
PKG_LICENSE:=GPLv2
|
||||||
@@ -10,7 +10,7 @@ PKG_LICENSE_FILES:=LICENSE
|
|||||||
|
|
||||||
PKG_SOURCE_PROTO:=git
|
PKG_SOURCE_PROTO:=git
|
||||||
PKG_SOURCE_URL:=https://github.com/GetPageSpeed/MTProxy.git
|
PKG_SOURCE_URL:=https://github.com/GetPageSpeed/MTProxy.git
|
||||||
PKG_SOURCE_VERSION:=eab5096fb539bb63d323e81c03130d408591cf41
|
PKG_SOURCE_VERSION:=92f9252c64d22ca907d8dbcd2885f6337ba9fa0d
|
||||||
|
|
||||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)
|
PKG_SOURCE_SUBDIR:=$(PKG_NAME)
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
|
|||||||
Reference in new issue
Block a user