mirror of
https://github.com/brunofontes/linuxShortcuts.git
synced 2024-11-24 06:34:56 +00:00
12 lines
285 B
Bash
12 lines
285 B
Bash
|
#/bin/sh
|
||
|
|
||
|
sleep 10s
|
||
|
wifi=$(iwconfig 2>/dev/null | grep Quasimodo)
|
||
|
if [[ -z $wifi ]]; then
|
||
|
echo "Starting OPEN VPN"
|
||
|
/usr/bin/systemctl restart openvpn-client@archerc6.service
|
||
|
else
|
||
|
echo "At home, no VPN for you"
|
||
|
/usr/bin/systemctl stop openvpn-client@archerc6.service
|
||
|
fi
|