This is a simple repository about how I learn Openvpn on a Ubuntu Server provided by Google Clound.
One reason i created this is to help myself remember the flow. Besides, I want to help those who struggle
with Openvpn and Clound Server.
Google Clound is very strong but complicated. First time I use Google Clound, I don't know what to do.
- When we create the instance, we need to have Allow full access to all Cloud APIs in Identity and API access
this will help us transfer file from remote to local. - remember to change the fire wall rule!!!.important
-
change to the root user
sudo su root -
change the root password
passwd -
change the user password using root user
passwd username
this will save us in the future, since google clound have no default password. but sometimes we need password to do sudo action.
- install wget
sudo apt install wget
-
Download the shell script provided by Nyr
wget https://git.io/vpn -O openvpn-install.sh && bash openvpn-install.sh. -
Change script into excutable
sudo chmod +x openvpn-install.sh -
Run the script using sudo
sudo ./openvpn-install.sh
It is ok to use the default setting except the name for the installation.
-
Change to the root user
su root. -
Using
cd ~change to the root folder -
Using
ls -l, you will find the filename.ovpnand this file is what we need to transfer to the local.
-
Create a bucket in clound storage in the Storage part.
-
Using the
gsutil cp name.ovpn gs://your-bucket -
Download the file in the bucket to you local computer.
- Download Openvpn client here.
- Drag the name.ovpn to the client.
Here we done