vpn: add wireguard watchdog

This commit is contained in:
Shiz 2022-08-24 20:52:42 +02:00
parent d44b01019b
commit 73b1862173
1 changed files with 8 additions and 0 deletions

View File

@ -35,4 +35,12 @@ commit network
add_list firewall.vwan.network=wg
commit firewall
EOI
# setup re-resolve
[ -d /etc/crontabs ] || mkdir /etc/crontabs
if ! [ -f /etc/crontabs/root ] || ! grep -q wireguard_watchdog /etc/crontabs/root; then
echo "* * * * * $(which wireguard_watchdog)" >> /etc/crontabs/root
/etc/init.d/cron enable
/etc/init.d/cron start
fi
fi