Step stucked fetching submodules (Github)


Step in the build is stucked waiting for the input with following output:

The authenticity of host ' (' can't be established.                                                                                       
RSA key fingerprint is SHA256:nThbg6kXUpJWGl7E1IGOCspRomTxdCARLviKw6E5SY8.                                                                                       
Are you sure you want to continue connecting (yes/no/[fingerprint])?


There is no github server key added inside known_host

Add extra step with following content:

title: Fetch submodules
working_directory: $
image: codefreshio/git-image:latest
  - mkdir ~/.ssh
  - echo $ > ~/.ssh/id_rsa
  - chmod 600 ~/.ssh/id_rsa
  - sudo ssh-keyscan -t rsa >> ~/.ssh/known_hosts

Where $ is your SSH private key

You can find more information about this topic in the following links: