mynode/rootfs/standard/usr/bin/mynode_vpn.sh
2019-08-12 22:29:53 -05:00

16 lines
308 B
Bash
Executable File

#!/bin/bash
apt -y update
while [ true ]; do
if [ ! -f /home/pivpn/ovpns/mynode_vpn.ovpn ]; then
/usr/bin/mynode_setup_vpn.sh
mkdir -p /home/pivpn/ovpns
pivpn add -n mynode_vpn -p bolt -d 3650
fi
systemctl enable openvpn
systemctl start openvpn
sleep 365d
done