SSH keys
Save your public SSH keys once and choose them when you create or reinstall an instance, so you can sign in as root without a password.
Add a key
- Open SSH keys in the sidebar.
- Give the key a name (e.g. "Chirag's laptop") and paste the public key, e.g. the contents of
~/.ssh/id_ed25519.pub. It starts withssh-ed25519,ssh-rsaorecdsa-sha2-…. - Select Add key.
Never paste a private key (it starts with -----BEGIN). The portal rejects it.
Each key shows its fingerprint (SHA256:…), the same value ssh-keygen -lf ~/.ssh/id_ed25519.pub prints, so you can check which key is which. A key can only be saved once per organization. Owners, Admins and Developers can add and delete keys; everyone in the organization can see them.
Use a key
When you create an instance or reinstall one, choose a saved key under SSH key, or paste a key just for that instance. One key is installed for root; to let more people in, add their keys to /root/.ssh/authorized_keys on the server.
Keys are only installed when an instance is created or reinstalled. Deleting a saved key does not remove it from instances that already have it; remove it from /root/.ssh/authorized_keys on the server.
Using the API
- List:
GET /api/v1/organizations/{id}/ssh-keys - Add:
POST /api/v1/organizations/{id}/ssh-keyswithnameandpublic_key - Delete:
DELETE /api/v1/organizations/{id}/ssh-keys/{key} - When creating or reinstalling an instance, pass either
ssh_key_ids(a list with one saved key's ID) orssh_key(a public key).