~/.ssh/id_rsa.pub not found error while installing capistrano as ansible playbook

I try to install https://github.com/roots/bedrock-ansible to get a bedrock deployment running.

When I run “vagrant up”, after some time I get the error:

TASK: [capistrano-setup | Setup deploy group] ********************************* 
skipping: [default]

TASK: [capistrano-setup | Setup deploy user] ********************************** 
skipping: [default]

TASK: [capistrano-setup | Adding public key to server] ************************ 
fatal: [default] => could not locate file in lookup: ~/.ssh/id_rsa.pub

FATAL: all hosts have already failed -- aborting

PLAY RECAP ******************************************************************** 
           to retry, use: --limit @/Users/johannes/site.retry

default                    : ok=46   changed=16   unreachable=1    failed=0   

Ansible failed to complete successfully. Any error output should be
visible above. Please fix these errors and try again.

I do not have a clou how i can fix this. Do you have an idea?

Well the error is pretty clear: could not locate file in lookup: ~/.ssh/id_rsa.pub

The playbook tries to copy your SSH public key to the server and it’s not found. See https://help.github.com/articles/generating-ssh-keys/ for instructions (ignore the part about adding it to GitHub).

1 Like

fatal: [default] => could not locate file in lookup: ~/.ssh/id_rsa.pub

looks like it could not locate file ~/.ssh/id_rsa.pub

You need to generate an SSH keypair. Authentication & Authorisation

1 Like

Thank you!

I thought the file was missing on the guest machine, so i was confused…