Get SSH Access¶
Progress: Module 1 of 4 → Page 1 of 3
Overview¶
In this lesson, you'll gain SSH access to the EgyGeeks server. SSH (Secure Shell) is how you'll connect to the server, deploy applications, and manage your infrastructure.
Time: 10-15 minutes
Prerequisites Checklist¶
Before you start, verify you have:
- A computer with SSH client (macOS/Linux: built-in, Windows: Git Bash or PuTTY)
- Admin contact information (email or Slack handle)
- A text editor for key management
- Basic familiarity with terminal/command line
Step 1: Contact the Admin¶
The first step is to request server access from the team admin.
Action Steps¶
- Locate the admin contact
- Check your team Slack/Discord
- Look in the team wiki or documentation
-
Common admin names: Lead Developer, DevOps Lead, or Team Manager
-
Send access request
- Message: "Hi [Admin Name], I'd like to request SSH access to the server. I'm [Your Name] and I'll be working on [Project Name]."
- Provide your full name and email address
-
Include your GitHub username (if applicable)
-
Wait for response
- Response time: Usually within 24 hours
- They'll provide you with:
- Server IP address (e.g.,
50.3.85.110) - Username to use for SSH
- Instructions for the next step
- Server IP address (e.g.,
Ask AI for Help
Copy this prompt to Claude or ChatGPT:
Step 2: Generate SSH Key (Local Machine)¶
Once you receive confirmation from the admin, generate an SSH key pair on your local machine.
Why SSH Keys?¶
SSH keys are more secure than passwords. They use public/private cryptography: - Public key (shared with server): Like a mailbox - Private key (kept secret): Like the mailbox key
Generate Key¶
On macOS/Linux:
# Generate SSH key (press Enter for default location)
ssh-keygen -t ed25519 -C "your-email@example.com"
# Follow prompts:
# - Save to: press Enter (default: ~/.ssh/id_ed25519)
# - Passphrase: Enter a secure passphrase (or press Enter to skip)
On Windows (Git Bash):
What Gets Created¶
After running the command, you'll have:
~/.ssh/
├── id_ed25519 # Your PRIVATE key (KEEP SECRET!)
└── id_ed25519.pub # Your PUBLIC key (share with admin)
View Your Public Key¶
# Display your public key
cat ~/.ssh/id_ed25519.pub
# Output looks like:
# ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKkZk... your-email@example.com
Ask AI for Help
Copy this prompt to Claude or ChatGPT:
I just ran this command to generate an SSH key:
ssh-keygen -t ed25519 -C "your-email@example.com"
I have two files now:
- ~/.ssh/id_ed25519
- ~/.ssh/id_ed25519.pub
Can you explain:
1. What's the difference between these two files?
2. How does public/private key authentication work?
3. Why is this more secure than passwords?
4. Which one do I share with the server admin?
Step 3: Share Public Key with Admin¶
Now share your public key with the admin so they can add it to the server.
Action Steps¶
-
Copy your public key
-
Send to admin
- Message: "Hi [Admin], here's my SSH public key. Please add it to my account."
- Paste the key in your message
-
Double-check you're sharing the
.pubfile, not the private key! -
Confirm with admin
- Ask: "Can you confirm you've added my key?"
- Wait for confirmation before proceeding
Important: Never share your private key (id_ed25519). Only share the public key (id_ed25519.pub).
Security Check with AI
I'm about to share my SSH key with the server admin. I want to make sure I'm sharing the right file.
I have:
- ~/.ssh/id_ed25519 (private key)
- ~/.ssh/id_ed25519.pub (public key)
Questions:
1. Which file should I send to the admin?
2. What happens if I accidentally share the wrong file?
3. How can I tell the difference between them?
4. Is it safe to paste the public key in Slack/email?
Step 4: Test Your Connection¶
Now test that you can connect to the server using SSH.
Connect to Server¶
# SSH to the server
ssh username@50.3.85.110
# First time connection, you'll see:
# "The authenticity of host '50.3.85.110' can't be established..."
# Type 'yes' and press Enter to continue
Replace username with the username the admin provided.
Successful Connection¶
If everything works, you'll see:
You're now connected to the server! You can type commands here.
Verify Your Setup¶
Run this command on the server to verify:
Having Issues? Debug with AI
I'm trying to connect to the EgyGeeks server but it's not working.
Command I'm using:
ssh username@50.3.85.110
My setup:
- Operating System: [macOS/Linux/Windows]
- SSH key location: ~/.ssh/id_ed25519
- Admin confirmed my key was added: [yes/no]
Error output:
[paste your error message here]
What's wrong and how do I fix it?
Verification Steps¶
Complete these checks to verify you have access:
- You can run
ssh username@50.3.85.110and connect - The server prompts you for a passphrase (if you set one)
- You see the welcome message: "Welcome to EgyGeeks Server!"
- You can run
whoamiand see your username - You can run
ls -la /opt/appsand see available applications
Troubleshooting¶
Connection Refused¶
Problem: ssh: connect to host 50.3.85.110 port 22 (tcp) Connection refused
Solutions: 1. Check the IP address is correct (ask admin to confirm) 2. Make sure you're using the correct username 3. Verify your public key was added to the server 4. Check that your firewall isn't blocking port 22
Debug Connection Issues with AI
SSH connection is being refused when I try to connect.
Error message:
ssh: connect to host 50.3.85.110 port 22 (tcp) Connection refused
Troubleshooting steps I've tried:
- [x] Verified IP address with admin: 50.3.85.110
- [ ] Checked my username is correct
- [ ] Confirmed my public key was added
- [ ] Tested firewall settings
What else should I check? How do I debug SSH connection refused errors?
Permission Denied¶
Problem: Permission denied (publickey,password).
Solutions: 1. Verify your public key was added to ~/.ssh/authorized_keys on server 2. Check key permissions: ls -la ~/.ssh/ should show id_ed25519 as 600 3. Regenerate your key pair and resend to admin 4. Ask admin to manually add your key
Keys Not Found¶
Problem: ssh: Could not resolve hostname
Solutions: 1. Check you have internet connection 2. Verify the IP address is correct 3. Try: ssh -v username@50.3.85.110 for verbose output 4. Check firewall rules
Summary¶
You've successfully: - Requested SSH access from the admin - Generated a secure SSH key pair - Shared your public key with the admin - Connected to the server - Verified your access
Congratulations! You now have full access to the EgyGeeks server.
What's Next?¶
Now that you have server access, let's understand what's running on the server.
Next Lesson: 2. Server Tour
Previous Lesson: Module Overview
Need Help?¶
Common Questions¶
Q: Is my private key safe if I press Enter (no passphrase)? A: It's less secure, but common for development. For production access, use a passphrase.
Q: Can I have multiple SSH keys? A: Yes! You can generate multiple keys for different servers or purposes.
Q: What if I lose my private key? A: You'll need to generate a new one and ask the admin to update it on the server.
Quick Reference¶
# Generate SSH key
ssh-keygen -t ed25519 -C "your-email@example.com"
# View your public key
cat ~/.ssh/id_ed25519.pub
# Connect to server
ssh username@50.3.85.110
# View key permissions (should be 600)
ls -la ~/.ssh/id_ed25519
Still Stuck?¶
Debug Common Issues with AI
SSH Key Setup Issues:
I'm having problems with my SSH key setup for server 50.3.85.110.
What I've done:
- Generated key with: ssh-keygen -t ed25519 -C "email@example.com"
- Sent public key (~/.ssh/id_ed25519.pub) to admin
- Admin confirmed it's added
Current issue:
[describe your problem]
Error message:
[paste error here]
How do I debug this SSH key setup?
Connection/Access Issues:
- Still need help? Message the admin with the error message
- Need more details? See OpenSSH Documentation
Tags: Getting Started, SSH, Access, Server Setup
Module: 1 of 4 | Page: 1 of 3