- Update:
apt update && apt -y full-upgrade. - Automatic security updates:
apt install -y unattended-upgrades. - Firewall:
ufw allow OpenSSH && ufw allow 80,443/tcp && ufw enable. - Brute-force protection:
apt install -y fail2ban. - SSH keys and a non-root user:
adduser deploy && usermod -aG sudo deploy.
Spam, scanning, DDoS or phishing from your server gets it blocked by the provider within a day.
