What Are SSH Keys?
SSH keys come in pairs:- Private Key - Stays on your local machine and must be kept secret
- Public Key - Can be safely shared with servers you want to access
Generating SSH Keys
For Linux and macOS
Open your terminal and run:- Choose a location (press Enter to use the default
~/.ssh/id_ed25519
) - Set a passphrase (optional but recommended for extra security)
~/.ssh/id_ed25519
- Your private key (keep this secret!)~/.ssh/id_ed25519.pub
- Your public key (share this with services)
For Windows
Option 1: Using Windows Subsystem for Linux (WSL) Open WSL terminal and use the same command as Linux/macOS above. Option 2: Using PuTTYgen- Download and install PuTTY
- Open PuTTYgen
- Click “Generate” and move your mouse to create randomness
- Save both the private and public keys
- Copy the public key text from the window
SSH Key Best Practices
Security
- Never share your private key - Only share the public key (
.pub
file) - Use a passphrase - Adds an extra layer of security
- Set proper permissions - Your private key should only be readable by you:
Organization
- Use descriptive names - If you have multiple keys, name them clearly:
- Keep backups - Store your keys securely in case your machine fails
SSH Keys with TensorPool
Adding Your SSH Key to Your Account
You can add SSH keys to your TensorPool account in two ways: Option 1: Using the CLI--name
flag is optional but helps you identify specific keys.
Option 2: Using the Dashboard
Visit tensorpool.dev/dashboard/ssh-keys to manage your SSH keys through the web interface. You can add, view, and remove keys from there.
Using SSH Keys with Clusters
When creating a TensorPool cluster, provide your public SSH key:-i
flag specifies the path to your public key file (the one ending in .pub
).
For more details on using SSH keys with TensorPool clusters, see SSH Keys.
Troubleshooting
Permission Denied
If you get “Permission denied (publickey)”, check that:- You’re using the correct private key
- The corresponding public key was added to the cluster
- Your private key has the correct permissions (
chmod 600
)
Key Not Found
If SSH can’t find your key, specify it explicitly:Multiple Keys
If you have multiple SSH keys, you can configure SSH to use specific keys for specific hosts by editing~/.ssh/config
:
Next Steps
- Create your first cluster
- Learn about cluster management
- See the CLI reference