Reputation: 3960
I have a Bitbucket account and I used my SSH key
as the deployment key
by accident and now when I try to enter my SSH key I get the infamous Someone has already registered this as a deploy key
. I'm the only person using this account, no one else.
Also, if I git push -u origin --all
I get:
conq: repository access denied. access via a deployment key is read-only.
fatal: Could not read from remote repository.
When the deployment key
was deleted already. I even deleted my account and created a new one and still getting Someone has already registered this as a deploy key
.
I'm trying to push from Cloud9 to Bitbucket so I don't know if creating a new SSH key is an option.
I don't know what else to do and neither the guys at Bitbucket. Any help? Thanks.
Upvotes: 0
Views: 3146
Reputation: 30197
Resolution
Open a terminal with SSH configured for Bitbucket Cloud and enter the following
ssh -T [email protected]
https://confluence.atlassian.com/bbkb/someone-has-already-registered-that-ssh-key-338365482.html
Upvotes: 0
Reputation: 3960
I was doing commit and push without git init
. That's why it kept telling Someone has already registered that SSH key.
Upvotes: 1
Reputation: 84443
The deployment key is obviously attached to some BitBucket team or repository somewhere, so unless you can track it down the easiest thing to do is just create a new keypair. This is easy enough to do, and will save you much pain and suffering.
Making a new key takes moments. Ensuring that you distribute your new key takes a bit longer, but still may be less trouble than tracking down a public key that's escaped into the wild. Upload your new public key to BitBucket as an account key, not as a deployment key. Then use /usr/bin/ssh-copy-id from the openssh-client package to quickly distribute the new key to your various internal servers, if you like.
Your problem could be resolved within minutes if you take the easy path. I heartily recommend it.
Upvotes: 1