1

I'm new to developing with GITHUB on a mac. I have created the SSH public and private key files and have the public key in the settings on git hub. I moved the files to the ~/.ssh folder on my mac.

The issue is that when I try to push to the remote branch, I get an access denied.

Jims-MacBook-Pro-2:romannumeralconverterAPI jrieck$ git push --set-upstream origin master
Enter passphrase for key '/Users/jrieck/.ssh/id_rsa': 
Enter passphrase for key '/Users/jrieck/.ssh/id_rsa': 
ERROR: Permission to jrieckPillarTechnology/ArabicToRomanNumeralAPI.git denied to deploy key
fatal: Could not read from remote repository.

Please make sure you have the correct access rights and the repository exists.
Jims-MacBook-Pro-2:romannumeralconverterAPI jrieck$ 

Any thoughts on the reason for the access denied error?

2
  • It looks like your key is protected with a passphrase, and you've entered it incorrectly. Commented Jan 13, 2019 at 18:48
  • Did you set up your personal key as a deploy key? Probably need to not do that.
    – Ry-
    Commented Jan 13, 2019 at 19:02

1 Answer 1

1

It sounds like you've set up your key as a deploy key, which are by default read-only. The idea behind a deploy key is that you can have an automated system use that key to access a specific repository for the purpose of deploying it to production. You can read more about why deploy keys are useful in the GitHub documentation.

If you're going to be using this key with your account as a human, not for an automated process, you probably want to remove it as a deploy key and instead add it as a key for your account, as described in the GitHub documentation for adding an SSH key. Note that you'll need to remove the key as a deploy key first; if you don't, you won't be able to add it as a key for your account.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.