Set passwordless SSH from A to B:
- Run
ssh-keygen
into the machine you want to ssh from(A) cd
into~/.ssh
- make a directory if not exist in the machine you want to ssh to(B) -->
mkdir ~/.ssh/
cp id_rsa.pub USER@IP_OF_B:~/.ssh/authorized_keys
The above line will copy id_rsa.pub, into the machine you want to ssh to(B), in the directory ~/.ssh/authorized_keys