usermod -aG sudo sydney

  • User Modification: usermod changes user settings.
  • Append Group (-aG): It adds the user sydney to the sudo (SuperUser DO) group

ufw allow OpenSSH

  • Uncomplicated Firewall: ufw is your server’s security guard.
  • The Rule: This creates a “hole” in the firewall specifically for Port 22 (SSH).
  • The Result: It ensures that when you turn the firewall on, you don’t accidentally lock yourself out of the server.

ufw enable

  • The Result: This officially turns the security guard “on.” From this point forward, every single port on your server is blocked by default except for the OpenSSH one you just allowed.

chmod 700 ~/.ssh

  • Change Mode: chmod sets permissions
  • 700 means “The owner can do everything (Read/Write/Execute), but everyone else can do nothing.”
    • The Result: This secures the folder where your keys live.
  • 600 means “The owner can Read/Write, but no one else can even look at it.”
    • The Result: This is the specific “safety level” SSH requires for your authorized_keys file.

sudo chown sydney:sydney ~/.ssh/authorized_keys

  • Change Owner: When you copied the key from the root account, the file was owned by “root.”
  • The Result: This hands ownership of that file over to the sydney user so the system knows it’s actually yours.

df -h

  • Check disk space

sudo ss -tulpn

  • to see what your server is currently doing
  • tulpn: It’s a bit of a mouthful, but it stands for TCP, UDP, Listen, Process, and Numeric. It shows you exactly which apps are sitting on which ports.

sudo ufw status

  • See status of firewall

docker ps

  • See all running containers and their names

docker logs <container_name>

  • Check logs for a container