Page 1 of 1
Connecting via CLI?
Posted: Wed Aug 25, 2021 11:04 am
by Peregrino69
OS Win 10, OpenVPN Connect ver 3.3.1 (2222)
I'm trying to create a bat file that would first connect my WiFi, and once that's established connect VPN. Starting WiFi connection with netsh works, but not the VPN connection. Command
Code: Select all
openvpnconnect <full path>\profile.ovpn
loads the GUI and shows the available profiles. What I'd like to happen is the client to actually connect using the defined profile.
Is that even possible, if yes, how?
Re: Connecting via CLI?
Posted: Fri Aug 27, 2021 10:38 am
by Peregrino69
Should I understand "No, there's no way to have Windows OpenVPN client connect automatically when launched from CMD", or am I just being hasty?
Re: Connecting via CLI?
Posted: Fri Aug 27, 2021 11:45 am
by Peregrino69
So far looks like the answer is indeed no, not possible with OpenVPN Connect. Only with the OpenVPN Community client 2.5.3.
Re: Connecting via CLI?
Posted: Mon Aug 30, 2021 11:54 am
by openvpn_inc
Hello Peregrino69,
OpenVPN Connect v3.3 has command line parameters for configuring the client program, importing, renaming, deleting of profiles, and other options. In a future release we will add more command line parameters to control the connection from the command line.
At this time if you need command line support for connecting, use the community client.
Kind regards,
Johan
Re: Connecting via CLI?
Posted: Wed Sep 01, 2021 1:48 pm
by Peregrino69
Thank you, Johan
Importing profiles and all that jazz worked well enough with the Connect client. I was just missing that last step, automatic connection w/o user intervention.
The community client indeed provides that, good enough for my current needs. I hope Connect client gets the same functionality in the future.