Bash script for automatic change between 2 Wireguard tunnels

Well today noticed (should test it more while checking from rest of LAN devices) a lag on streaming service after this solution switched to different route.

It turns out, as I'm on 22.03 with PBR using nft - it is incompatible with mwan3.

(Should put that info in first post, but didn't know atm. Have some feelings with the 'opkg install iptables-nft' as it's some previously used solution, possibly from PBRs docs. but didn't fully realize it until today.)

As noted here (same thread both info):

In that case possibly only new installation of PBR with the iptables could work:

Not willing to do that. Likely to stay with something tested, easily maintainable and if there is possibly update of OpenWRT I'm rather on newer version with packages to be installed easily and configs working out of the box.

But for anyone who doesn't use PBR - this still is usable solution.

So must push the script forward.