getclient: Do not autogenerate key
* Do not autogenerate a key if it does not exist. Instead fail. * Requires users to explicitly generate keys and prevents generating erroneous keys in the event of a typo.
This commit is contained in:
		@@ -10,7 +10,8 @@ source "$OPENVPN/ovpn_env.sh"
 | 
			
		||||
cn=$1
 | 
			
		||||
 | 
			
		||||
if [ ! -f "$EASYRSA_PKI/private/${cn}.key" ]; then
 | 
			
		||||
    easyrsa build-server-full $cn nopass
 | 
			
		||||
    echo "Unable to find ${cn}, please try again or generate the key first"
 | 
			
		||||
    exit 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
cat <<EOF
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user