fatal: Unable to create temporary file '/home/username/git/myrepo.git/./objects/pack/tmp_pack_XXXXXX': Permission denied

前端 未结 8 1043
独厮守ぢ
独厮守ぢ 2020-12-23 09:00

I have been having trouble with this error message and I don\'t understand the proper solution to fix it or go about debugging it. I have googled the error in various forms

8条回答
  •  北海茫月
    2020-12-23 09:32

    It sounds like you have file in the git repo owned by root. Since you're ssh'ing in as 'username' to do the push, the files must be writable by username. The easiest thing is probably to create the repo as the user, and use the same user to do your pushes. Another option is to create a group, make everything writable by the group, and make your user a member of that group.

提交回复
热议问题