Unfortunately I have an error which is : Host key verification failed.
According to the support, my configuration at kinsta is well configured and the problem would come from gitlab. But I have looked at several posts and I did not find anything.
Can you post the entire error message for Host Key verification failed? This is normally to do with SSH, and it will most likely reference in that error message to a line number in ~/.ssh/known_hosts of which it’s usually because of a key conflict because it changed on the server because it was reinstalled, or something else similar eg if the same IP was used previously for another server before it was installed with Gitlab perhaps.
since if the key hasn’t been accepted yet, then it will ask do you want to accept it yes/no. Alternatively, you can also do this in your CI file just before the SSH command:
then you can use the ssh command without passing additional parameters. The echo commands only needs to be done once, say at the beginning of the section, then all future ssh commands will use the config file.
A sample .gitlab-ci.yml where I do the same thing:
as you can see in the second example, I pass the additional parameter on the command line, rather than setting it globally for all hosts in .ssh/config.
Thank you for your answer, it may indeed interest me too.
With the iwalker method I managed to establish a connection. But your code may interest me too. I’m doing the tests with the other method and I’ll look at yours later.