EC2 supplies an OpenSSL encrypted "pem" private key. Sometimes you just need the ssh public key version of this file.
There are a few ways to do this using openssl and other tools, but I prefer using ssh-keygen to create a public key from a private key.
This will print out the public key from any given private key. Works with EC2 pem files.
Just drop the output of this command into ~/.ssh/authorized_keys and you should be good to go!
There are a few ways to do this using openssl and other tools, but I prefer using ssh-keygen to create a public key from a private key.
ssh-keygen -y -f yourprivatekey.pem
This will print out the public key from any given private key. Works with EC2 pem files.
No comments:
Post a Comment