How to implement a VPN

Implementing a VPN for fun(?) and business continuation
iot iiot tech

How to implement a VPN

Sometimes you would want to be in your office, because you need to press that very button, just now, and you wish you had not left, you need to come back, start your machine again, start all the environment, double check if it’up. And all this because you moved, you had to be somewhere else.

Without further explanations, because you know the issue, you experienced exactly this same problem many times, let’s spend a few words about the solution.

What you need is a VPN. A VPN is a Virtual Private Network, that means it looks like a local LAN, where you can access resources, but it’s made of machines distributed over different networks. In order to implement this, you need:

A good setup

Edit the content of openvpn-setup.cfg:

code_country="SE"
code_province="KA"
code_city="SomeCity"
code_organization="YourOrganization"
code_email="some@email.net"
vpn_port="1194"

How to create the server

You can usee the following script to create the server:

./openvpn-create-server.sh

Create the clients

You can usee the following script to create a client: myclient

./openvpn-create-client.sh myclient

Retrieve a sample config