In an attempt to allocate a public IP to a server inside my network i have the following scenario:
VPS running Centos 7 and OpenVPN server with public IP
220.127.116.11 on interface
Local server: LAN IP 10.2.0.140 (on interface eth0) WAN IP 18.104.22.168 (on interface eth1) with gateway 22.214.171.124
OpenVPN Client on local server is connecting to the VPS with OpenVPN server without any problems.
tun0 IP for VPN server is 10.8.0.1 tun0 IP for VPN client is 10.8.0.2
When the VPN is connected and I do an IP lookup with "
curl ifconfig.co" I get the VPS IP address of
126.96.36.199, thats good.
What I not want to do if forward some ports to the WAN IP of the local server.
From the VPS/VPN Server I can ping
10.8.0.2, but not