The authenticity of host 'bitbucket.org (xxx.xxx.xxx.xxx)' can't be established

When I’m using a custom docker image for my android build I get the error mentioned below.

Strangely using the circleci images like circleci/android:api-27-alpha works fine. How do I fix the issue for my custom image hosted in dockerhub.

Cloning into ‘.’…
The authenticity of host ‘bitbucket.org (xxx.xxx.xxx.xxx)’ can’t be established.
RSA key fingerprint is SHA256:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx.
Are you sure you want to continue connecting (yes/no)?

Possible duplicates:

If none of those cover your case, have a look at the CircleCI shell code in the checkout step to see what it is doing. It might give you a clue as to what keys it is looking for or where it is trying to find them.

I had changed my user to root and seems I need to switch back to circleci for the checkout to work correctly.

My docker file looks like this now

#0 give root access for installations
USER root

RUN this
RUN that

#n Give back control to circleci 
USER circleci
1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.