Stage 1 · Lesson 9 of 10
SSH keys and remote access
is how you log in to remote servers and copy files to them. Instead of a password, you use a key pair: two matching files made with ssh-keygen -t ed25519. The private key stays on your machine, readable only by you (mode 600).
The public key goes on the server, in ~/.ssh/authorized_keys. Keys are far safer than passwords. Once key-based login works, turn off password login and root login in sshd_config.
A ~/.ssh/config file saves typing by giving each host a short name, with its user and key. scp and rsync copy files over the same kind of connection. Every later stage relies on this: cloud servers, hosting and many deploy steps all use SSH keys.
Common trapcopying one private key onto several machines or sharing it with a teammate, which makes it impossible to revoke one person's access without breaking everyone's.
A question to check yourself, an AI practice session and 1 cheat sheet entry come with the full roadmap. Unlock
Resources for this stage
Start with· follow one of these
- CourseFreeThe Missing Semester of Your CS Education
MIT · Beginner
Shell, scripting, data wrangling, SSH and Git in a dozen focused lectures
- BookFreeThe Linux Command Line
William Shotts · Beginner
Free book: permissions, processes, packages and longer shell scripts, chapter by chapter