mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
Fix stop proxy redirection in case if restarted and still down
This commit is contained in:
parent
ad7ecd87e2
commit
eae54dd7a2
1 changed files with 2 additions and 1 deletions
|
@ -159,7 +159,8 @@ while true; do
|
|||
last=$((last + 1 ))
|
||||
[ -z "$nocontact" ] && nocontact="$host" || nocontact="$nocontact, $host"
|
||||
[ "${last}" -ge "${retry}" ] && {
|
||||
if [ "$OMR_TRACKER_PREV_STATUS" != "ERROR" ] && { [ -n "$($IPTABLES -w -t nat -L -n 2>/dev/null | grep ssr)" ] || [ -n "$(nft list ruleset 2>/dev/null | grep ss_r)" ] || [ -n "$(nft list ruleset 2>/dev/null | grep ssr_r)" ]; }; then
|
||||
#if [ "$OMR_TRACKER_PREV_STATUS" != "ERROR" ] && { [ -n "$($IPTABLES -w -t nat -L -n 2>/dev/null | grep ssr)" ] || [ -n "$(nft list ruleset 2>/dev/null | grep ss_r)" ] || [ -n "$(nft list ruleset 2>/dev/null | grep ssr_r)" ]; }; then
|
||||
if [ -n "$($IPTABLES -w -t nat -L -n 2>/dev/null | grep ssr)" ] || [ -n "$(nft list ruleset 2>/dev/null | grep ss_r)" ] || [ -n "$(nft list ruleset 2>/dev/null | grep ssr_r)" ]; then
|
||||
_log "Shadowsocks $type ${server} is down (can't contact via http ${nocontact})"
|
||||
OMR_TRACKER_STATUS_MSG="Shadowsocks $type ${server} is down (can't contact via http ${nocontact})"
|
||||
uci -q set openmptcprouter.omr.ss_${server}="down"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue