Secure a new server from minute one: a sudo user, SSH key login, firewall, Fail2ban, swap and automatic updates, plus Docker and Nginx if you want. Pick options and copy a ready Bash script.
Create the script nowSimple steps, all in your browser with no sign-up.
Ubuntu or AlmaLinux.
User, key, firewall, Fail2ban.
As root.
| Option | Why |
|---|---|
| sudo user | You work as it daily instead of root, avoiding full-power mistakes |
| SSH key, no passwords | Stops password-guessing attacks entirely |
| Change SSH port | Cuts automated login noise in logs, but is not protection on its own |
| Firewall | Closes every port except those you need |
| Fail2ban | Bans addresses that keep failing to log in |
| Swap | Disk-backed memory that keeps services alive when RAM fills |
| Automatic updates | Security patches install without waiting for you |
| Command | What it shows |
|---|---|
ufw status verbose | Open ports (Ubuntu) |
firewall-cmd --list-all | Open ports (AlmaLinux) |
fail2ban-client status sshd | Banned addresses |
free -h | Memory and swap |
df -h | Disk usage |
journalctl -u ssh -n 50 | Latest login logs |
Short definitions of what you meet along the way.
Did not find your answer? Ask us on WhatsApp
On recent Ubuntu, Debian, AlmaLinux and Rocky Linux. Try it on a fresh server before one with live sites.
That is why you keep the session open while testing. If it happens, use the console in your provider's panel.
No. cPanel has its own settings and firewall; this script is for bare servers.
No. The script is built in your browser.
It depends on your projects. Try the VPS calculator on the servers page.
VPS servers, and we can prepare them for you on request.
We use necessary cookies to run the site, and Google Analytics to measure visits only if you agree. You can change your choice at any time from “Cookie settings”. Privacy policy