If you getting following error:
Using SSH executor...
ERROR: Preparation failed: ssh command Connect() error: getting host key callback: open /root/.ssh/known_hosts: no such file or directory
Will be retried in 3s ...
Follow the steps to resolve:
1) Login to gitlab
instance via SSH
2) Become sudo
via:
sudo su
3) Now, you need to connect gitlab instance to the host where runner is try to connect
ssh <host-username>@<host-ip>
<host-username>
and <host-ip>
should match with the gitlab runner
, it will ask for password
then it will ask to accept key fingerprint
.
Now, try to run the job with the runner. It should be working
Top comments (0)