mirror of
https://github.com/gSpotx2f/ruantiblock_openwrt.git
synced 2026-05-13 14:10:59 +00:00
Minor fixes.
This commit is contained in:
@@ -10,7 +10,7 @@ LUCI_APP=1
|
|||||||
HTTPS_DNS_PROXY=1
|
HTTPS_DNS_PROXY=1
|
||||||
|
|
||||||
OWRT_VERSION="25.12"
|
OWRT_VERSION="25.12"
|
||||||
RUAB_VERSION="2.1.11-r1"
|
RUAB_VERSION="2.1.11-r2"
|
||||||
RUAB_MOD_LUA_VERSION="2.1.11-r1"
|
RUAB_MOD_LUA_VERSION="2.1.11-r1"
|
||||||
RUAB_LUCI_APP_VERSION="2.1.11-r1"
|
RUAB_LUCI_APP_VERSION="2.1.11-r1"
|
||||||
BASE_URL="https://raw.githubusercontent.com/gSpotx2f/packages-openwrt/master"
|
BASE_URL="https://raw.githubusercontent.com/gSpotx2f/packages-openwrt/master"
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ LUCI_APP=1
|
|||||||
HTTPS_DNS_PROXY=1
|
HTTPS_DNS_PROXY=1
|
||||||
|
|
||||||
OWRT_VERSION="24.10"
|
OWRT_VERSION="24.10"
|
||||||
RUAB_VERSION="2.1.11-r1"
|
RUAB_VERSION="2.1.11-r2"
|
||||||
RUAB_MOD_LUA_VERSION="2.1.11-r1"
|
RUAB_MOD_LUA_VERSION="2.1.11-r1"
|
||||||
RUAB_LUCI_APP_VERSION="2.1.11-r1"
|
RUAB_LUCI_APP_VERSION="2.1.11-r1"
|
||||||
BASE_URL="https://raw.githubusercontent.com/gSpotx2f/packages-openwrt/master"
|
BASE_URL="https://raw.githubusercontent.com/gSpotx2f/packages-openwrt/master"
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
|
|||||||
|
|
||||||
PKG_NAME:=ruantiblock
|
PKG_NAME:=ruantiblock
|
||||||
PKG_VERSION:=2.1.11
|
PKG_VERSION:=2.1.11
|
||||||
PKG_RELEASE:=1
|
PKG_RELEASE:=2
|
||||||
PKG_MAINTAINER:=gSpot <https://github.com/gSpotx2f/ruantiblock_openwrt>
|
PKG_MAINTAINER:=gSpot <https://github.com/gSpotx2f/ruantiblock_openwrt>
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
|
|||||||
@@ -1040,12 +1040,6 @@ CheckDnsmasqConfDir() {
|
|||||||
|
|
||||||
Update() {
|
Update() {
|
||||||
local _arg="$1" _return_code=0
|
local _arg="$1" _return_code=0
|
||||||
if CheckStatus; then
|
|
||||||
:
|
|
||||||
else
|
|
||||||
echo " ${NAME} ${_arg} - Error! ${NAME} does not running or another error has occurred" >&2
|
|
||||||
return 1
|
|
||||||
fi
|
|
||||||
MakeToken
|
MakeToken
|
||||||
if [ -e "$U_PID_FILE" ] && [ "$_arg" != "force-update" ]; then
|
if [ -e "$U_PID_FILE" ] && [ "$_arg" != "force-update" ]; then
|
||||||
echo " ${NAME} ${_arg} - Error! Another instance of update is already running" >&2
|
echo " ${NAME} ${_arg} - Error! Another instance of update is already running" >&2
|
||||||
@@ -1129,32 +1123,36 @@ Stop() {
|
|||||||
|
|
||||||
Reload() {
|
Reload() {
|
||||||
local _i=0 _attempts=60
|
local _i=0 _attempts=60
|
||||||
MakeToken
|
if CheckStatus; then
|
||||||
while [ -e "$START_PID_FILE" ]
|
MakeToken
|
||||||
do
|
while [ -e "$START_PID_FILE" ]
|
||||||
if [ $_i -ge $_attempts ]; then
|
do
|
||||||
return 1
|
if [ $_i -ge $_attempts ]; then
|
||||||
fi
|
return 1
|
||||||
_i=$(($_i + 1))
|
fi
|
||||||
|
_i=$(($_i + 1))
|
||||||
|
|
||||||
|
if [ $DEBUG -ge 1 ]; then
|
||||||
|
echo " ruantiblock.Reload._i=${_i}" >&2
|
||||||
|
MakeLogRecord "debug" "ruantiblock.Reload._i ${_i}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
|
||||||
if [ $DEBUG -ge 1 ]; then
|
if [ $DEBUG -ge 1 ]; then
|
||||||
echo " ruantiblock.Reload._i=${_i}" >&2
|
echo " ruantiblock.Reload()" >&2
|
||||||
MakeLogRecord "debug" "ruantiblock.Reload._i ${_i}"
|
MakeLogRecord "debug" "ruantiblock.Reload()"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sleep 1
|
echo " ${NAME} reload..."
|
||||||
done
|
DeleteNftRules &> /dev/null
|
||||||
|
AddNftRules &> /dev/null
|
||||||
if [ $DEBUG -ge 1 ]; then
|
UpdateLocalIpSets
|
||||||
echo " ruantiblock.Reload()" >&2
|
MakeToken
|
||||||
MakeLogRecord "debug" "ruantiblock.Reload()"
|
else
|
||||||
|
echo " ${NAME} does not running" >&2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo " ${NAME} reload..."
|
|
||||||
DeleteNftRules &> /dev/null
|
|
||||||
AddNftRules &> /dev/null
|
|
||||||
UpdateLocalIpSets
|
|
||||||
MakeToken
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Status() {
|
Status() {
|
||||||
@@ -1274,6 +1272,12 @@ case "$1" in
|
|||||||
;;
|
;;
|
||||||
update|force-update)
|
update|force-update)
|
||||||
Init
|
Init
|
||||||
|
if CheckStatus; then
|
||||||
|
:
|
||||||
|
else
|
||||||
|
echo " ${NAME} ${_arg} - Error! ${NAME} does not running or another error has occurred" >&2
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
UpdateLocalIpSets
|
UpdateLocalIpSets
|
||||||
if CheckDnsmasqConfDir; then
|
if CheckDnsmasqConfDir; then
|
||||||
Update "$1"
|
Update "$1"
|
||||||
|
|||||||
Reference in New Issue
Block a user