git post-receive hook not running

后端 未结 6 1973
被撕碎了的回忆
被撕碎了的回忆 2020-12-25 12:23

I have a bare repo server-side, and I am able to successfully commit and push from my local machine. However, the post-receive hook is not running. Details:

  • Us
6条回答
  •  天命终不由人
    2020-12-25 12:37

    I had the same problem on a Centos 6 system, where it turned out that SELinux prevented hooks scripts from running. Turning httpd_git_script_t into a permissive domain helped here (since "sesearch -A -s httpd_git_script_t -p exec" yielded nothing, ie. no process running in the httpd_git_script_t domain was allowed exec permission):

    semanage permissive -a httpd_git_script_t
    

提交回复
热议问题