How to attach a public key:


navigate to this location:


using commands: 


cd /home/ubuntu

cd .ssh



Then use command 


vi authorized_keys 


inside this file you will insert the text of the public key right below the other keys listed


be sure to wq and exit