How to use Ubuntu Droplet and OpenVPN to give your home NAS -> Public IP
Hi guys. I’m new here and this is my first post so please don’t get too rough on my idea. Basically the idea is to do as follows:
NAS —>ROUTER(NAT/No Public IP)—->INTERNET—–>Droplet(OpenVPN server)-PublicIP
Having my NAS on a very good connection but without public IP I want to configure it to act as a openvpn client and connect to my droplets openvpn server, which would act as both a firewall and provider of public ip adress. Configuring NAS and creating openvpn server on droplet is well documented. The hard part for is when it comes to configuring iptables. I don’t realy get it and apart from using ufw I don’t have any real experience using it. Could you guys be so kind to point me in the right direction with that iptables issue?
Step 1 - how to configure iptables to pass bidirectional traffic between two interfaces
Step 2 - how to configure iptables to pass bidirectinal traffic between two interfaces but just on selected ports
Please help ;)
PS. This is an old NAS which is used only for testing some ideas (for those of you who would like to point out that opening ones NAS to the Internet is a bad idea)