When you manage cloud servers, information security is a topic that cannot be compromised. One of the most common, simple, and effective solutions to enhance the security of your connection to a cloud server is using a VPN (Virtual Private Network). In the following guide, we will explain in simple terms how to set up a VPN for a secure connection to your server on OMC's cloud, quickly and easily.
Why Do You Need a VPN in the Cloud?
A cloud server, whether public or private, is usually accessible through the internet, making it vulnerable to hacking attempts. Using a VPN allows you to:
Create a secure, encrypted connection between your computer and the cloud server.
Provide secure access to your servers from anywhere in the world.
Protect against unauthorized access to your data.
Reduce risks and significantly improve information security.
Common Types of VPNs for Cloud Server Connection
There are several types of VPNs suitable for use in the cloud:
OpenVPN: Particularly popular, open-source, highly secure, and easy to install.
WireGuard: A modern, fast, lightweight, and highly secure VPN.
IPsec/L2TP: Older, but still common and provides excellent security.
In this guide, we will focus on OpenVPN, as it is one of the most widely used and trusted options today.
The Fastest Way: OpenVPN Server Built into OMC's Cloud Interface
In OMC’s cloud management interface, you can set up a VPN server with just one click, using a pre-configured OpenVPN template. This method allows you to set up a VPN server in less than 60 seconds, without the need for manual installation or advanced technical knowledge.
How to Do This?
Log in to OMC’s cloud interface (omc.cloud/he).
Click on “Create New Server”.
Choose the "OpenVPN" template from the list of available templates.
Select the appropriate specifications (CPU, memory, disk). - A minimal resource selection will suffice for this case, with a server that has 1 CPU, 2 GB of memory, and 30 GB of storage.
Once the setup is complete, you will immediately receive access to the login details for your OpenVPN server and can start using it for a secure and encrypted connection.
Benefits of Using the Built-in OpenVPN Template:
Quick and simple installation, with no prior technical knowledge required.
A stable and secure VPN environment with all recommended settings.
Time and effort savings compared to manual installation.
Advanced Option: Manual Installation of OpenVPN (For Experienced Users)
For those who want full control over the installation, here is a simple and short guide for manually installing the OpenVPN VPN on an OMC cloud server:
Step 1: Preparing the Server
Open the terminal and connect to your server via SSH:
bash
Copy
ssh username@server-ip-address
Update the operating system:
bash
Copy
sudo apt update && sudo apt upgrade -y
Step 2: Installing OpenVPN
Install OpenVPN using the popular and simple installation script by Angristan/OpenVPN-install:
Run the following commands:
bash
Copy
curl -O https://raw.githubusercontent.com/angristan/openvpn-install/master/openvpn-install.sh
chmod +x openvpn-install.sh
sudo ./openvpn-install.sh
The script will guide you through the installation steps in a simple and intuitive way:
Choose your server’s IP address.
Select the UDP protocol (recommended), or TCP if needed.
Choose a port (the default port is 1194).
Set the encryption type (AES-256-GCM is recommended).
Create a new user for your connection.
The installation will take only a minute or two.
Step 3: Connecting to Your VPN
After installation, you will receive a configuration file named username.ovpn.
Transfer this file to your personal computer:
bash
Copy
scp username@server-ip-address:/home/username/username.ovpn ~/Desktop/
Now, install the appropriate OpenVPN client on your computer:
Windows: OpenVPN Connect
macOS: Tunnelblick
Linux: NetworkManager-OpenVPN
Open the OpenVPN software on your computer and load the .ovpn file you received from the server.
VPN Connection Check
After connecting via the VPN:
Open the terminal or browser and check your public IP address.
Ensure it has changed to the IP address of your cloud server.
You are now securely connected to your server!
Summary
Using a VPN is one of the most important solutions for securing access to a cloud server. On OMC's cloud, you can choose between quickly setting up a VPN server from a built-in template or manually installing it, according to your preference.
OMC’s cloud servers are perfectly suited for VPN solutions, providing you with a stable, secure, and fast infrastructure.
Need further assistance?
OMC’s support experts are available for any questions or installation and consultation requests!