1.建LCX主机
2.修主配置文件以支持TUN
nano /etc/pve/lxc/100.conf
添加
lxc.cgroup.devices.allow: c 10:200 rwm
lxc.mount.entry: /dev/net dev/net none bind,create=dir
chown 100000:100000 /dev/net/tun
3.开始安装openvpn
wget https://git.io/vpn -O openvpn-install.sh(可能需要代理)
chmod +x openvpn-install.sh
./openvpn-install.sh (开始安装)
再次运行./openvpn-install.sh可以添加删除用户