Cannot push to repository - access rights

06tech April 9, 2022

I stating work on an existing project and my Atlassian account has have been added as an Admin to the repository and my SSH public key from my development laptop has also been added to the Access Keys list.

I tried to push up a new branch to the repo and receive this error (I've tried from command line and from Sourcetree - same result):-

Unauthorized
fatal: Could not read from remote repository.

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

 

NB: I have cloned the repo via SSH with no problems so read access is fine...

Any ideas on how to fix this?

Thanks

1 answer

0 votes
Karthick S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 10, 2022

Hello @06tech

Welcome to the Atlassian Community!

Access key in the repository provides READ-only access. Could you try adding the public SSH key in the Personal settings of the Bitbucket? 

Reference: https://support.atlassian.com/bitbucket-cloud/docs/set-up-an-ssh-key/

I hope this helps.

Kind regards,
Karthick S

06tech April 10, 2022

Thanks for your reply - when I try and add my SSH key to my account through Personal Settings I get an error:-

 

Someone has already added that key as an access key to a repository.

Karthick S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 10, 2022

Hello @06tech

Currently, it is not possible to add the same SSH key more than once. I believe you have mentioned you have added the SSH key in the repository as an access key. If yes, could you please remove it from the repository and then try adding the SSH Key in the Personal settings of the Bitbucket? 

Kindly keep us posted if you face any issues.

Kind regards,

Karthick S

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events