There are numbers of tutorials on the net on how to configure access from one machine to another without typing a password.
Here is the real way to do it.
First generate a pair of keys:
ssh-keygen -t rsa
It’s important to choose a passphrase. Don’t leave it blank.
Then you need to copy the public key to the other server
ssh-copy-id -i .ssh/id_rsa.pub>
Make sure that ssh-agent is running.
Add a key using ssh-add
ssh-add
Try connecting
Should be working.