This is an old revision of the document!
UFW is the default firewall configuration tool on Ubuntu and is simple to install on Debian.
https://www.digitalocean.com/community/tutorials/ufw-essentials-common-firewall-rules-and-commands
Getting Started: https://www.howtoforge.com/tutorial/ufw-uncomplicated-firewall-on-ubuntu-15-04/
ufw --force disable ufw --force reset ufw default deny incoming ufw default allow outgoing ufw allow 2222/tcp #Example ufw --force enable ufw status