Question

DO Network Firewall vs UFW

I have two droplets, one a DB server and one an application server. The DB server has a host-based UFW ruleset allowing access only to from a certain IP, specifically so that only the application server can communicate with it.

My question is, in a scenario like this, is DO’s Cloud Firewall preferable? My understanding is that this firewall is network-based, and would filter the traffic before it touches the host, potentially saving the host some resources.

Is this a correct assumption? And if so, would configuring the cloud firewall in this way eliminate the need for the UFW configuration?


Submit an answer


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!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Bobby Iliev
Site Moderator
Site Moderator badge
August 11, 2019

Hello,

Indeed you are correct, having a Cloud Firewall would essentially mean that the traffic would be filtered before it even reaches your server. This could be very beneficial in case of a big DDoS attack, that way the malicious traffic would not even reach your droplet.

It is not necessary to have a software firewall like UFW enabled even if you have a separate Cloud Firewall.

Hope that this helps! Regards, Bobby

alexdo
Site Moderator
Site Moderator badge
April 26, 2024

Heya,

DigitalOcean’s Cloud Firewall is a network-based one. The same firewall rules can be applied on a large number of Droplets. DigitalOcean’s Cloud Firewall has the advantage of scalability. As it supports tagging of the Droplets, we can add custom labels to Droplets.

UFW is a host-based tool. That is, it has to be configured on each Droplet separately and add the necessary rules manually.

https://www.digitalocean.com/community/tutorials/how-to-set-up-a-firewall-with-ufw-on-ubuntu

Regards

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more
DigitalOcean Cloud Control Panel