I'm trying to realize such functionality:
I have Win 10 PC with installed OpenVPN client. At this PC I already have installed and always running Mozilla Thunderbird mail client. I want the VPN client to connect to the server if Mozilla received the email.
For this behavior I'm plan to use such scheme: When incoming email is received by Mozilla, it's extension "Mailbox Alert" executes bat file, which run openvpn client which are connecting to server.
But I can't create bat file, which will able to cennect to VPN server.
I've trying this bat file:
Code: Select all
cd "C:\Program Files\OpenVPN\bin"
START "" /B openvpn.exe --config config.ovpn
How I can create bat file for connecting to OpenVPN server and adding routes for use in my automatization case?