ERROR: The key you are authenticating with has been marked as read only

Hi!

I’m working on custom step and I have issue with git when I’m trying to push my changes

Warning: Permanently added 'github.com,192.30.253.112' (RSA) to the list of known hosts.
ERROR: The key you are authenticating with has been marked as read only.
fatal: Could not read from remote repository.

I tried to add authenticate-with-github-oauth@0.9.1 step but it doesn’t help.

Ok, seems like I found answer on my question and this is how I fixed it:

  • Generate new key pair: ssh-keygen -f deploy_rw -N ''.
  • You wll have two files: deploy_rw.pub and deploy_rw.
  • Add to GitHub a deploy_rw.pub key.
  • Go to project settings in Bitrise and add the private key deploy_rw.
1 Like

Thanks for sharing the steps @ned!

Worth to mention we have a step by step guide here, about generating a suitable SSH key: https://devcenter.bitrise.io/faq/how-to-generate-ssh-keypair/

It’s important that the key has to have an empty passphrase, e.g.: ssh-keygen -t rsa -b 4096 -P '' -f ./bitrise-ssh

Happy Building! :slight_smile:

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