Host firewall vs cloud security groups: do you need both?
IntermediateProductionFirewalls, MAC & Compliance
Answer
Security groups / NSGs are the primary control in the cloud: stateful, enforced outside the VM (a compromised host cannot disable them), and managed with Terraform. A host firewall adds defence in depth, protects against misconfigured security groups, and can filter between processes on the same subnet. Many teams keep host firewalls minimal on cloud VMs and strict on bare metal. In Kubernetes nodes, avoid host firewalls that fight with CNI/kube-proxy rules.
More on Firewalls, MAC & Compliance
How do ufw, firewalld, nftables and iptables relate?BeginnerConfigure ufw for a web server with SSH only from the office.BeginnerExplain firewalld zones and runtime vs permanent configuration.IntermediateWrite a minimal nftables ruleset for a server.AdvancedWhy are nftables preferred over iptables at scale?AdvancedHow do you avoid locking yourself out when changing remote firewall rules?Intermediate