gitolite push error -> remote: ENV GL_RC not set

前端 未结 4 894
既然无缘
既然无缘 2020-11-30 09:38

I am trying to push content from a workstation to a server. But it gives me an error. Please look at the following for command and error:

Administrator@ganes         


        
4条回答
  •  不知归路
    2020-11-30 09:47

    As illustrated in the doc ssh troubleshooting, this is probably caused by an incorrect path during cloning.

    The documentation (some parts below were only valid for Gitolite V2) mentions:

    The second error

    (ie. "you are able to clone repositories but are unable to push changes back (the error complains about the GL_RC environment variable not being set, and the hooks/update failing in some way)

    happens if you use git@server:repositories/reponame.git (assuming default $REPO_BASE setting -- in Gitolite V3, it always is ~/repositories) -- that is, you used the full unix path.
    Since the "prefixing" mentioned above is not required, the shell finds the repo and clones ok.
    But when you push, gitolite's update hook kicks in, and fails to run because some of the environment variables it is expecting are not present.

    The message that appears on a successful run of the "easy-install" program clearly includes the following warning:

    *Your* URL for cloning any repo on this server will be
            gitolite:reponame.git
    
        *Other* users you set up will have to use
            @:reponame.git
        However, if your server uses a non-standard ssh port, they should use
            ssh://@:/reponame.git
    

    So in your case, you must have cloned your repo with:

    git clone git@ganesh:repositories/testing.git
    

    instead of:

    git@ganesh:testing.git
    

提交回复
热议问题