Table of Contents

Before Your Start

If you are looking for adding user (or yourself) to OpenVPN for support purposes, check out Setup Open VPN User 2018 Edition

Ubuntu 18.04 Open VPN Full installation as performed on on CA Server (AWS Northern California: Errigal CA - DO NOT DELETE) and Open VPN Server (olympus.err)

This article explains how to install Open VPN on Ubuntu 18.04. The steps followed came from this Tutorial:

————————————-

CA Machine (AWS Northern California: Errigal CA - DO NOT DELETE)

————————————-

OpenVPN Server Machine (olympus)

————————————-

CA Machine (AWS Northern California: Errigal CA - DO NOT DELETE)

————————————-

OpenVPN Server Machine (olympus)

————————————-

CLIENT KEY GEN on server (olympus)

————————————-

CA Machine (AWS Northern California: Errigal CA - DO NOT DELETE)

————————————-

OpenVPN Server Machine (olympus)

————————————-

Configure OpenVPN Server (olympus)

# START OPENVPN RULES
# NAT table rules
*nat
:POSTROUTING ACCEPT [0:0]
# Allow traffic from OpenVPN client to enp7s0 (change to the interface you discovered!)
-A POSTROUTING -s 10.8.0.0/8 -o enp7s0 -j MASQUERADE
COMMIT
# END OPENVPN RULES
# script-security 2
# up /etc/openvpn/update-resolv-conf
# down /etc/openvpn/update-resolv-conf
#!/bin/bash

# First argument: Client identifier

KEY_DIR=~/client-configs/keys
OUTPUT_DIR=~/client-configs/files
BASE_CONFIG=~/client-configs/base.conf

cat ${BASE_CONFIG} \
    <(echo -e '<ca>') \
    ${KEY_DIR}/ca.crt \
    <(echo -e '</ca>\n<cert>') \
    ${KEY_DIR}/${1}.crt \
    <(echo -e '</cert>\n<key>') \
    ${KEY_DIR}/${1}.key \
    <(echo -e '</key>\n<tls-auth>') \
    ${KEY_DIR}/ta.key \
    <(echo -e '</tls-auth>') \
    > ${OUTPUT_DIR}/${1}.ovpn

————————————-

Generate Client Configuration on OpenVPN Server (olympus)

————————————-

Your Client (i.e. your macbook)

————————————-

GENERATING NEW CLIENT CONFIGS (Quick)

Visit OpenVPN Server Machine (olympus.err)
Visit CA Machine (AWS Northern California: Errigal CA - DO NOT DELETE)
Visit OpenVPN Server Machine (olympus.err)
MAKE SURE YOU STOP THE AWS Nothern California: Errigal CA - DO NOT DELETE instance

START/STOP OpenVPN Server

Visit OpenVPN Server Machine (olympus.err)