First off, i just wanna say thank you to the diet-pi team, for their amazing contributions! My requiest is it add wireguard to your current Dietpi-NordPVN. Just like how you can use the command ‘nordvpn set technology nordlynx’ to switch to wireguard protocol from openvpn. Thanks!
I would also like to thank the DietPi team for building and supporting this awesome platform… thanks everyone!
I agree with Lvsdark that this would be an awesome function. It would be great to use the cool "edit up’ and “edit down” script feature (which ensures privacy for other services is the VPN fails), to access the Nordlynx service.
Whether that is using the current NordVPN app or separate one (if OpenVPN and Wireguard can’t co-exist)…
Any support on this would be awesome!
Cheers,
Max
i’m far far far from an expert, but i have managed to throw together the following script as a pseudo if-up/down script for using nordlynx
#!/bin/sh
# Check vpn-tunnel "nordlynx" and ping google DNS if internet connection work
if [ "$(ping -I nordlynx -q -c 1 -W 1 8.8.8.8 | grep '0% packet loss' )" != "" ]; then
# if-up commands
echo "vpn up"
else
#if-down commands
echo "vpn down"
fi
(its a modified code shared by joulinar on a spereate thread)
i made it executable (chmod +x) then popped it in /etc/cron.minutely/nordlynx (no .sh at the end or dietpi-cron won’t execute it)
If you wanted a more frequent interval than minutely then i don’t see why you couldn’t repeat the code with “sleep 1” (or however many seconds you want between checks).
not perfect, but good enaough for me. i’m just using it to kill deluged (which runs socks5 anyway so if it takes a minute to notice then i can live with that).
By putting a ‘systemctl start deluged’ in the if-up command then it should relaunch deluged when the vpn s back up