For Oracle VPS servers (Oracle Cloud Infrastructure)
We eliminate IPTables
sudo systemctl enable ufw
sudo ufw allow 22
sudo ufw enable
sudo apt remove netfilter-persistent
sudo reboot
We restart the server
sudo reboot
Access as "root"
sudo su
As always, first make sure your system has up-to-date packages.
apt update
Next, install the dependencies.
apt -y install ca-certificates wget net-tools gnupg
We added the OpenVPN server to its repository list.
wget https://as-repository.openvpn.net/as-repo-public.asc -qO /etc/apt/trusted.gpg.d/as-repository.asc
echo "deb [arch=amd64 signed-by=/etc/apt/trusted.gpg.d/as-repository.asc] http://as-repository.openvpn.net/as/debian jammy main"> /etc/apt/sources.list.d/openvpn-as-repo.list
Finally, update and install the OpenVPN server.
apt update
apt -y install openvpn-as
Copy the key of the "openvpn" user that is provided to you at the end of the configuration.