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

Merge branch 'test' into develop

This commit is contained in:
antrouter 2021-03-30 22:21:23 +08:00
commit bbb7909fe4
4 changed files with 12 additions and 5 deletions

View file

@ -26,6 +26,8 @@ export OMR_TRACKER_DEVICE_GATEWAY
export OMR_TRACKER_DEVICE_GATEWAY6
export OMR_TRACKER_IPV6
export OMR_TRACKER_PROTO
export OMR_TRACKER_INTERVAL_TRIES
export OMR_TRACKER_INTERVAL
dscp=56 # set DSCP CS7 (56) in outgoing packets
initial_hosts="$OMR_TRACKER_HOSTS"

View file

@ -75,7 +75,7 @@ while true; do
uci -q set openmptcprouter.omr.v2ray="up"
uci -q commit openmptcprouter.omr
}
if [ -z "$(iptables -t nat -L -n | grep v2r)" ]; then
if [ -z "$(iptables -w -t nat -L -n | grep v2r)" ]; then
_log "Reload V2Ray rules"
/etc/init.d/v2ray rules_up 2> /dev/null
_get_ip
@ -86,7 +86,7 @@ while true; do
last=$((last + 1 ))
[ -z "$nocontact" ] && nocontact="$host" || nocontact="$nocontact, $host"
[ "${last}" -ge "${retry}" ] && {
if [ -n "$(iptables -t nat -L -n | grep v2r)" ]; then
if [ -n "$(iptables -w -t nat -L -n | grep v2r)" ]; then
_log "V2Ray is down (can't contact via http ${nocontact})"
uci -q set openmptcprouter.omr.v2ray="down"
uci -q commit openmptcprouter.omr