# generate key files (public key & private key)
ssh-keygen -t rsa -m pem
# (optional) rename the private key file
mv id_rsa id_rsa.pem
# read the public key file
cat id_rsa.pub
# append the public key to the authorized_keys file
vim ~/.ssh/authorized_keys