1

我正在关注本教程

在这一步之后:

$ git commit -a -m "Allow jdoe write access to free_monkey"
$ git push

我总是失败,出现这个错误:

fatal: exec hooks/post-update failed.

这是来自我的/home/git/repositories/gitosis-admin/hooks/post-update

-rwxr-xr-x 1 git git   83 Mar 10 11:49 post-update

所以我gitosis.conf从服务器手动更改以添加新的存储库,并且 repos 可以正常工作。

我已经用谷歌搜索了可能导致它的原因,我想以适当的方式管理 gitosis。

请帮忙

问候, REV

4

1 回答 1

0

您的更新后挂钩可以执行,但它不能更新和中的指针refs/heads/refs/remotes/这有助于使用“哑”协议进行克隆,即通过 http)

检查与您的 gitosis 回购相关的权利,尤其是在.git/refs

还要检查是否<git>/bin/git-update-server-info是可执行的
(你可以尝试——作为测试——update-hook用一个链接替换你的git-update-server-info,就像这个案例)。
或者,如此处所述,检查您是否需要更换gitosis/templates/admin/hooks/post-update

git-update-server-info

git update-server-info
于 2010-03-12T12:22:13.940 回答