Skip to content
Guest
Learn Linux · Course Syllabus Show lessons
Server Administration · 8 min read · Beginner

SSH Keys & Zero-Friction rsync Deploys

Authenticate to Linux servers securely with Ed25519 SSH keys and sync builds fast using rsync -avz --delete.

What you'll learn

  • Generate strong Ed25519 SSH key pairs with ssh-keygen -t ed25519
  • Understand why public keys (.pub) go into ~/.ssh/authorized_keys while private keys never leave your machine
  • Deploy static or backend builds fast with rsync -avz --delete

SSH keys replace brittle passwords with public-key cryptography. Only your public key (~/.ssh/id_ed25519.pub) is added to the server’s ~/.ssh/authorized_keys; your private key stays locked down (chmod 600) locally. Once SSH works, rsync -avz --delete uploads only changed files in seconds.

Fill-in-the-Blank Exercise

Sync Build Folder with rsync

Archive, compress, and remove stale remote files when deploying dist/.

 -avz -- dist/ root@server:/var/www/app/

Live Bash Lab

Bashdeploy_checklist.sh
Expected OutputClick “Run Live” to compile with GNU Bash
# 1. Generate modern Ed25519 deploy key
ssh-keygen -t ed25519 -C "deploy@devpath"

# 2. Deploy only changed files over SSH
rsync -avz --delete dist/ root@server:/var/www/app/

Check Your Understanding

Score: 0 / 1

1. Which SSH key file should you copy into a remote server's ~/.ssh/authorized_keys?

Study Workspace

Finished this lesson?

Your progress is saved locally in your browser, no account needed.

Search courses, lessons, and references

Type to search across all courses, lessons, and quick references.

Press Esc to close Powered by Pagefind