简体   繁体   中英

Add remote server as git remote

I tried to add a Git remote with

git remote add remote-server ssh://domain_name.com/opt/test/testapp.git

git push remote-server master

The problem is that I am trying to push from the local server as user 'kute', and the file opt/test/testapp.git is owned by another user, say 'test'. So, when I run git push remote-server master , I get the following permission issue:

fatal: Unable to create temporary file: Permission denied error: pack-objects died of signal 13 error: failed to push some refs to

Is there any solution to this permission issue?

You must not push directly to remote repository own by another person.

You must use a "share" repository and add your public ssh key in the .ssh/authorized_keys file of the unix user that own the "share" repository.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM