In many cases you may need to access your box through ssh with a password. This may be the case if you have not installed certificates yet. You should temporarily enable access with password and when your job is done disable it. In the case of an Ubuntu machine it can be enabled for the whole system by altering /etc/ssh/sshd_config:
Then restart the ssh server:
This change will affect all users of the server.