agentleFS
shali10shali10/awesome-agent-skills/skills/vps-bootstrap/SKILL.md

vps-bootstrap

Skill1 starsChanged 2 months agoMITView on GitHub

Use when provisioning, benchmarking, and hardening a fresh Linux VPS node with SSH security, UFW firewall, Fail2ban, BBR acceleration, and hardware health inspection.

  • Installs packages

The file

We split this skill into the rules it gives an agent

1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Locking out SSH during UFW enable: Always explicitly run ufw allow <YOUR_SSH_PORT>/tcp BEFORE running ufw enable.

    line 67

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Fresh Linux VPS Bootstrap & Security Hardening

Overview

A battle-tested initialization and security baseline suite for new Linux VPS nodes (Debian/Ubuntu/AlmaLinux). It automates hardware & network benchmarking, BBR+FQ TCP acceleration, UFW firewall rules, Fail2ban brute-force protection, SSH key authentication enforcement, and system package updates.

When to Use & When NOT to Use

When to Use

  • Initializing a brand-new VPS instance right after purchase/reinstall.
  • Establishing standard security baselines on exposed cloud VMs.
  • Auditing CPU speed, disk I/O, swap, and three-network routing quality.

When NOT to Use

  • Managing container-internal virtual filesystems where kernel tuning (BBR/Swap) is restricted by host hypervisors.
  • Production systems with active complex iptables routing that could be overwritten by naive UFW enable.

Standard Initialization Pipeline

# 1. Update packages & install essential tools
apt-get update && apt-get install -y ufw fail2ban curl wget git htop jq iotop

# 2. Enable BBR + FQ TCP Congestion Control
cat << 'EOF' >> /etc/sysctl.conf
net.core.default_qdisc = fq
net.ipv4.tcp_congestion_control = bbr
EOF
sysctl -p

# 3. Configure UFW Firewall (Never lock out SSH!)
ufw default deny incoming
ufw default allow outgoing
ufw allow 22/tcp comment 'SSH Port'
ufw allow 80/tcp comment 'HTTP'
ufw allow 443/tcp comment 'HTTPS'
ufw --force enable

# 4. Configure Fail2ban for SSH Protection
cat << 'EOF' > /etc/fail2ban/jail.local
[sshd]
enabled = true
port = 22
filter = sshd
logpath = /var/log/auth.log
maxretry = 5
bantime = 86400
findtime = 600
EOF
systemctl restart fail2ban

Common Pitfalls

  1. Locking out SSH during UFW enable: Always explicitly run ufw allow <YOUR_SSH_PORT>/tcp BEFORE running ufw enable.
  2. Debian 12/13 auth.log missing for Fail2ban: Debian 12+ defaults to systemd-journald instead of rsyslog. Set backend = systemd in /etc/fail2ban/jail.local if /var/log/auth.log does not exist.
  3. Docker bypassing UFW: Docker by default manipulates iptables directly and bypasses UFW rules. Bind container ports to 127.0.0.1:<port> or configure DOCKER-USER chain rules.

Verification Checklist

  • sysctl net.ipv4.tcp_congestion_control returns bbr.
  • ufw status verbose shows active status with open SSH port.
  • fail2ban-client status sshd confirms active jail.
  • Root password login is disabled in /etc/ssh/sshd_config (PasswordAuthentication no).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.