Check vpn client template exists
This commit is contained in:
parent
c432d69551
commit
54bc008961
|
@ -123,6 +123,11 @@ y
|
|||
|
||||
user_vpn_cert_file=/home/$username/$OPENVPN_KEY_FILENAME
|
||||
|
||||
if [ ! -f /usr/share/doc/openvpn/examples/sample-config-files/client.conf ]; then
|
||||
echo $'No VPN client template found'
|
||||
exit 429823
|
||||
fi
|
||||
|
||||
cp /usr/share/doc/openvpn/examples/sample-config-files/client.conf $user_vpn_cert_file
|
||||
sed -i "s|remote .*|remote $DEFAULT_DOMAIN_NAME 1194|g" $user_vpn_cert_file
|
||||
sed -i 's|;user nobody|user nobody|g' $user_vpn_cert_file
|
||||
|
|
Loading…
Reference in New Issue