1) I create a new repo on bitbucket using the main TEAM user.
2) Then i add all development keys that will be able to download this repo.
3) Went to a server and made a clone of this repo using the command:
git clone ssh://[email protected]/user/repo.git
4) I made some changes to the code and made the commit
git commit -a -m "some improves"
So here's the Question:
I can't do a git push bec i don't have push right to do that with this user:
# git push
conq: repository access denied. access via a deployment key is read-only.
fatal: The remote end hung up unexpectedly
So, how can i make a push using my username/password?
You could always setup a second remote on your server using https:
git remote add edit-only-origin https://bitbucket.org/user/repo.git
Then, you could make small edits, commit and then use the command
git push edit-only-origin
This would prompt you for both your username and password.
From my understanding, deployment key
is for read-only access. To be able to push, you need to add your computer's ssh
key.
Go to Manage Account, and on the left, choose SSH keys. Add key by copy and pasting your rsa.pub public key.
It's better if you copy it from terminal to make sure no funky characters get in the mix. To do so in OSX, type pbcopy < ~/.ssh/id_rsa.pub
. For Linux, look at Agush's comment.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With