Auto restart VPN if disconnected

I have done this change on my setup to fix the random disconnection I am facing.

If the VPN go down, wait and reconnect to the vpn
* add 5 second delay
* call /rw/config/rc.local script
This commit is contained in:
kakooloukia 2021-06-05 18:07:51 +02:00 committed by GitHub
parent 5971998494
commit 20c6e78faf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -207,6 +207,10 @@ Before proceeding, you will need to download a copy of your VPN provider's confi
;;
down)
su - -c 'notify-send "$(hostname): LINK IS DOWN !" --icon=dialog-error' user
# Restart the VPN automatically
sleep 5s
sudo /rw/config/rc.local
;;
esac
~~~