[Resolved] Script for OpenVPN connection

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Jonmo1

[Resolved] Script for OpenVPN connection

Post by Jonmo1 »

So I have the line below to connect to OpenVPN. It works great. But I have to manually enter passwords and such.
I'm hoping to have a script to run make the connection.

I can run this manually from Terminal.
sudo openvpn /etc/openvpn/Houston_udp.ovpn

It first prompts for my sudo password of coarse. I would not object to being prompted for that password.
But I would like to have the openvpn credentials automatically entered for me.


Any help would be appreciated. Thanks.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: Script for OpenVPN connection

Post by catweazel »

Jonmo1 wrote: Sat Aug 17, 2019 6:35 pm So I have the line below to connect to OpenVPN. It works great. But I have to manually enter passwords and such.
I'm hoping to have a script to run make the connection.
You should be able to import the VPN configuration into Mint's network manager. From there, you can import the certificate and automatically connect to the VPN when a connection is made. There should be no need for a script at all.

https://torguard.net/knowledgebase.php? ... icle&id=53

That's for ubuntu but it should give you at least the outline of what to do.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
Jonmo1

[Resolved] Script for OpenVPN connection

Post by Jonmo1 »

Wow, I was making it harder than it needed to be (I'm good at that).

Thanks a ton, that worked perfectly.
Last edited by Jonmo1 on Sat Aug 17, 2019 7:44 pm, edited 1 time in total.
User avatar
catweazel
Level 19
Level 19
Posts: 9763
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: Script for OpenVPN connection

Post by catweazel »

Jonmo1 wrote: Sat Aug 17, 2019 7:42 pm Wow, I was making it harder than it needed to be (I'm good at that).

Thanks a ton, that worked perfectly.
:) My pleasure.
"There is, ultimately, only one truth -- cogito, ergo sum -- everything else is an assumption." - Me, my swansong.
Locked

Return to “Networking”