ssh-keygen
to store the keys in a safe location so you can bypass the login prompt when connecting to your instances.ssh-keygen
utility prompts you to indicate where to store the key.ssh-keygen
utility prompts you for a passphrase.id_rsa
file in the .ssh
directory and is used to verify the public key you use belongs to the same Triton Compute Service account.Never share your private key with anyone! |
---|
id_rsa.pub
;file and is the key you upload to your Triton Compute Service account. You can save this key to the clipboard by running this:id_rsa
) does not match the public key stored with your Triton Compute Service account.triton
and CloudAPI as well as the triton-docker
commandline tool.ssh-keygen -t rsa
cat ~/.ssh/id_rsa.pub | ssh [email protected] 'mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys
where ~/.ssh/id_rsa.pub is the new key on your machine and [email protected] is the username and IP address of your EC2 instance.vim ~/.ssh/authorized_keys
Just go to the line with the old key and remove it: dd
Note: If you tried editing the file and didn’t save it, or the connection was interrupted, an .authorized_keys.swp file will be created, and the next time you try to edit your authorized_keys, you will get a nasty message. Just delete the .swp file, and you should be good to edit.