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

Fixes for test speed scripts

This commit is contained in:
Ycarus (Yannick Chabanois) 2023-08-08 21:55:28 +02:00
parent d889f6f629
commit 6cbb420ffa
3 changed files with 30 additions and 16 deletions

View file

@ -43,7 +43,7 @@ trap : HUP INT TERM
if [ -z "$INTERFACE" ]; then
curl -4 -o /dev/null $HOST || echo
else
: /etc/init.d/sqm stop $INTERFACE
/etc/init.d/sqm stop $INTERFACE
domain=$(echo $HOST | awk -F/ '{print $3}')
hostip=$(dig +nocmd +noall +answer A $domain | grep -v CNAME | awk '{print $5}' | tr '\n' ' ')
if [ -n "$(ipset list 2>/dev/null | grep ss_rules)" ]; then
@ -62,5 +62,5 @@ else
ipset del ss_rules_dst_bypass_all $ip
done
fi
: /etc/init.d/sqm start $INTERFACE
/etc/init.d/sqm start $INTERFACE
fi