diff --git a/UnblockNeteaseMusic/Makefile b/UnblockNeteaseMusic/Makefile index ac767afa..e07fcf5c 100644 --- a/UnblockNeteaseMusic/Makefile +++ b/UnblockNeteaseMusic/Makefile @@ -5,14 +5,14 @@ include $(TOPDIR)/rules.mk PKG_NAME:=UnblockNeteaseMusic -PKG_BASE_VERSION:=0.27.5 +PKG_BASE_VERSION:=0.27.6 PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL:=https://github.com/UnblockNeteaseMusic/server.git -PKG_SOURCE_DATE:=2024-02-21 -PKG_SOURCE_VERSION:=369ec698635aa60512dc35d88c7d4385bd2ea5e1 -PKG_MIRROR_HASH:=6ba4ec6b4ed249a948f07b95ae5b74766006dcb9c4690f7e337efdc03f34859b +PKG_SOURCE_DATE:=2024-03-14 +PKG_SOURCE_VERSION:=efd157705254b3502315bbb55348c79e8fda7f02 +PKG_MIRROR_HASH:=d2779566daa0cd057b8b0054f16159c67c41914b653733a8405f1e33eae4f8a1 PKG_VERSION:=$(PKG_BASE_VERSION)-$(PKG_SOURCE_DATE)-$(call version_abbrev,$(PKG_SOURCE_VERSION)) diff --git a/homeproxy/root/etc/init.d/homeproxy b/homeproxy/root/etc/init.d/homeproxy index f15e416c..488d3a41 100755 --- a/homeproxy/root/etc/init.d/homeproxy +++ b/homeproxy/root/etc/init.d/homeproxy @@ -139,6 +139,7 @@ start_service() { config_get tun_mark "infra" "tun_mark" "102" ip tuntap add mode tun user root name "$tun_name" + sleep 1s ip link set "$tun_name" up ip route replace default dev "$tun_name" table "$table_mark" @@ -306,9 +307,6 @@ stop_service() { ip -6 route del local ::/0 dev lo table "$table_mark" 2>"/dev/null" # TUN - ip link set "$tun_name" down 2>"/dev/null" - ip tuntap del mode tun name "$tun_name" 2>"/dev/null" - ip route del default dev "$tun_name" table "$table_mark" 2>"/dev/null" ip rule del fwmark "$tun_mark" table "$table_mark" 2>"/dev/null" @@ -349,6 +347,17 @@ stop_service() { log "Service stopped." } +service_stopped() { + # Load config + config_load "$CONF" + local tun_name + config_get tun_name "infra" "tun_name" "singtun0" + + # TUN + ip link set "$tun_name" down 2>"/dev/null" + ip tuntap del mode tun name "$tun_name" 2>"/dev/null" +} + reload_service() { log "Reloading service..." diff --git a/luci-app-homeproxy/root/etc/init.d/homeproxy b/luci-app-homeproxy/root/etc/init.d/homeproxy index f15e416c..488d3a41 100755 --- a/luci-app-homeproxy/root/etc/init.d/homeproxy +++ b/luci-app-homeproxy/root/etc/init.d/homeproxy @@ -139,6 +139,7 @@ start_service() { config_get tun_mark "infra" "tun_mark" "102" ip tuntap add mode tun user root name "$tun_name" + sleep 1s ip link set "$tun_name" up ip route replace default dev "$tun_name" table "$table_mark" @@ -306,9 +307,6 @@ stop_service() { ip -6 route del local ::/0 dev lo table "$table_mark" 2>"/dev/null" # TUN - ip link set "$tun_name" down 2>"/dev/null" - ip tuntap del mode tun name "$tun_name" 2>"/dev/null" - ip route del default dev "$tun_name" table "$table_mark" 2>"/dev/null" ip rule del fwmark "$tun_mark" table "$table_mark" 2>"/dev/null" @@ -349,6 +347,17 @@ stop_service() { log "Service stopped." } +service_stopped() { + # Load config + config_load "$CONF" + local tun_name + config_get tun_name "infra" "tun_name" "singtun0" + + # TUN + ip link set "$tun_name" down 2>"/dev/null" + ip tuntap del mode tun name "$tun_name" 2>"/dev/null" +} + reload_service() { log "Reloading service..."