git update-server-info无所作为 [英] Git update-server-info nothing do

查看:291
本文介绍了git update-server-info无所作为的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

目标:在网络服务器上托管git存储库,而没有git程序和git deamon(将HTTP用作传输协议,将dump用作git协议-没有脚本,没有shell,仅

Goal: hosting git repository on web server without git program and git deamon (used HTTP as transfer protocol and dump as git protocol - nothing scripts, nothing shell, only GET supported).

我使用的教程来自: http://git-scm.com/book/en/Git-Internals-Transfer-Protocols

步骤:


  1. 创建一个新的git存储库。

  2. 克隆为--bare到grepo.git

  3. 在grepo.git中调用 git update-server-info(文件无任何更改!)

  4. mv hooks / post- commit.sample hooks / post-commit&& chmod a + x hooks / post-commit

  5. 调用 git clone http:// example.com/grepo.git

  1. Create a new git repo.
  2. Clone as --bare to grepo.git
  3. call "git update-server-info" in grepo.git (nothing file change!)
  4. mv hooks/post-commit.sample hooks/post-commit && chmod a+x hooks/post-commit
  5. call "git clone http:// example.com/grepo.git

在客户端得到:致命的:http:// example.com/grepo.git/info/refs?service=git-upload-pack找不到:您是否运行了git update-server-info在服务器上?

On client side got: fatal: http:// example.com/grepo.git/info/refs?service=git-upload-pack not found: did you run git update-server-info on the server?

在服务器端的请求日志中:[20 / Jun / 2013:11:45:16 +0200] GET /grepo.git/info/ refs?service = git-upload-pack HTTP / 1.1 404 1385

On server side in request log: [20/Jun/2013:11:45:16 +0200] "GET /grepo.git/info/refs?service=git-upload-pack HTTP/1.1" 404 1385

为什么git在服务器上调用任何脚本?
我的git版本是1.8.1.5。

Why git call any script on server? My git version is 1.8.1.5.

推荐答案

您可以检查repo.git / info / refs权限以查看Web服务器进程是否可读。

You may check repo.git/info/refs permissions to see if it is readable by web server process.

这篇关于git update-server-info无所作为的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆