I’ve set up a VPC with two droplets following the article at https://www.digitalocean.com/docs/networking/vpc/resources/droplet-as-gateway/. I have a problem where backend droplet cannot connect to the Internet through the gateway when firewall is enabled on the gateway droplet.
Firewall rules on the gateway allow access from anywhere on usual ssh, http and https ports. When I disable the firewall on the gateway, backend droplets can connect to the internet without a problem.
What should I change so that backend droplets can connect to the Internet through the gateway with its firewall enabled?
Thanks in advance!
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Accepted Answer
I found that ufw blocks routed traffic by default, so rules need to be added separately to allow such traffic to pass through.
https://askubuntu.com/questions/161346/how-to-configure-ufw-to-allow-ip-forwarding
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.