Jenkins deployment key is not associated with the repository Using jenkins to pull from bitbucket repository, I got this error:

git@bitbucket.org:source/source.git +refs/heads/:refs/remotes/origin/&quot; returned status code 128:
stdout:
stderr: repository access denied. deployment key is not associated with the requested repository.
fatal: Could not read from remote repository.

I have added ssh keys in the bitbucket repo, I have run ssh -v git@bitbucket.org and this is the output:

authenticated via a deploy key.
You can use git or hg to connect to Bitbucket. Shell access is disabled.
This deploy key has read access to the following repositories:
source/source: root.staging_quc -- root@QUICKRESPONSE
debug1: channel 0: free: client-session, nchannels 1
Connection to bitbucket.org closed.
Transferred: sent 2968, received 1872 bytes, in 0.0 seconds
Bytes per second: sent 82471.7, received 52017.2
debug1: Exit status 0

I don't really know what to do, hope you guys have any clue on this one I will update this question
First make sure that you added the public key to the right repo with the right permission, usually I add it to 'Access keys' so the user has read only permission, then to make sure that is working add the private key to you system so you can use it with using git:

ssh-add private-key
git clone &lt;your git repo&gt;


If it's working, add those credential to you jenkins and use them later