Error pushing to GitHub - insufficient permission for adding an object to repository database

后端 未结 21 2209
孤街浪徒
孤街浪徒 2020-11-27 09:34

I\'m getting back an unusual error while trying to do a \"git push\" to my GitHub repository:

Counting objects: 8, done.
Delta compression using 2 threads.
Compre         


        
21条回答
  •  天涯浪人
    2020-11-27 10:05

    Usually this problem is caused by wrong user and group permissions on your Git servers file-system. The git repository has to be owned by the user and also his group.

    Example:

    If your user is called "git", his group "gitgroup", and the location of the Git repo is: git@mygitserverxyz.com:path/to/repo.git

    then do a:

    sudo chown -R git:gitgroup path/to/repo.git/

    This fixed the git insufficient permission error for me.

提交回复
热议问题