Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI failure at "Checkout code" step - fatal: Could not read from remote repository. #1012

Open
Rob--W opened this issue Mar 28, 2022 · 1 comment

Comments

@Rob--W
Copy link
Member

Rob--W commented Mar 28, 2022

https://app.circleci.com/pipelines/github/mozilla/FirefoxColor/1087/workflows/8f5362d6-3b2b-498f-8fab-e4ba07ea3820/jobs/2787

Here is the end of the log:

Using SSH Config Dir '/home/circleci/.ssh'
git version 2.34.1
Cloning git repository
Cloning into '.'...
Warning: Permanently added the ECDSA host key for IP address '140.82.113.4' to the list of known hosts.
[email protected]: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

exit status 128

CircleCI received exit code 128

For the record, [email protected]:mozilla/FirefoxColor.git and as part of the checkout the following logic is run:

export GIT_SSH_COMMAND='ssh -i "$SSH_CONFIG_DIR/id_rsa" -o UserKnownHostsFile="$SSH_CONFIG_DIR/known_hosts"'

# use git+ssh instead of https
git config --global url."ssh://[email protected]".insteadOf "https://github.com" || true
git config --global gc.auto 0 || true

if [ -e '/home/circleci/FirefoxColor/.git' ] ; then
  echo 'Fetching into existing repository'
  existing_repo='true'
  cd '/home/circleci/FirefoxColor'
  git remote set-url origin "$CIRCLE_REPOSITORY_URL" || true
else
  echo 'Cloning git repository'
  existing_repo='false'
  mkdir -p '/home/circleci/FirefoxColor'
  cd '/home/circleci/FirefoxColor'
  git clone --no-checkout "$CIRCLE_REPOSITORY_URL" .
fi
@diox
Copy link
Member

diox commented Mar 28, 2022

Do you have a Deploy Key set up in CircleCI, and authorized with GitHub for this repo?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants