Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

permission denied

Mohamed Bachir Miguil
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
December 7, 2023

Hello, I want to "git push" after a "git commit", but I have this message : 

git@bitbucket.org: Permission denied (publickey).
fatal: Could not read from remote repository.

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

Here are the steps I have taken to solve this problem : 
1. create an ssh-key 
2. added the public key to bitbucket 
3. edited ~/.ssh/config file to add the path of my private key 

I have also explored different solutions but didn't success to solve this issue. thanks for the help

1 answer

1 vote
Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
December 8, 2023

Hi Mohamed and welcome to the community!

Could you please share the following info so I can better help you?

1. What are the permissions of the .ssh directory, the public key file, and the private key file on this computer?

2. Could you please push using the following command and share the full output of the command here?

GIT_SSH_COMMAND="ssh -vvv" git push

This command will print verbose output so we can check which key is being offered, if the options from ~/.ssh/config are applied, and any additional errors.

Please make sure to sanitize any private/sensitive data in the output (e.g. workspace-id, repo name) before sharing.

Kind regards,
Theodora

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events