Open tunnelblick vpn connection from terminal

Tunnelblick is a great free openvpn client on Mac Os X.

But somehow you must have access to desktop to using it. And I need to open vpn connection from terminal, not with fancy clicking on GUI.

After searching across universe (I mean google) I find it very simple:

sudo /Applications/Tunnelblick.app/Contents/Resources/openvpn --cd "/Users/%USER%/Library/Application Support/Tunnelblick/Configurations" --config client.ovpn --daemon

Of course, you can have different paths (but I bet they are not), and different configuration name (mine is client.opvn) but in general, this is it.

I am still trying to find a way how to read password for private key from some file or keychain (i know, i know, security and stuff) and how to close vpn session (now I just kill process) but it works.

In case of trouble you have two friends. First is –help and second is console.app.

In same dir you can found /Applications/Tunnelblick.app/Contents/Resources/openvpnstart which was my first choice. And I lost hour, trying to figure out what is this shit for, and why do I need some –management and similar to simply connect to open vpn server. Probably this stuff support much more than simple client I need.