git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Error in creating git over http

From
SAShlomit Afgin <shlomit.afgin@weizmann.ac.il>
Date
Oct 8, 2013, 15:05 UTC
Message-ID
<51123DD1BF2E03418A1296748DA730927454504A@ibwmbx03>
In-Reply-To
<51123DD1BF2E03418A1296748DA730927454460F@ibwmbx03>
I'm trying to set a http git server.
I do the following on the git server:
       cd /var/www/html/
git clone --bare  /path/to/dir/ gitproject.git
cd gitproject.git/
mv hooks/post-update.sample hooks/post-update
chmod a+x hooks/post-update

on the local machine run: git clone http://server.name/gitproject.git

I got the error: "Initialized empty Git repository in /local/path/gitproject/.git/ fatal: http://server.name/gitproject.git/info/refs not found: did you run git update-server-info on the server?"

I saw that the file does not exist, it seem that the file post-update is not execute.

I run it on the git server: git update-server-info

Now the info/ref is created.

On local machine I run again : git clone http://server.name/gitproject.git

Now I get the error:
  Initialized empty Git repository in /local/path/gitproject/.git/
error: The requested URL returned error: 403 (curl_result = 22, http_code
= 403, sha1 = 9d83b83df9fbc75ecd754264f95793fca93ccf93)
error: Unable to find 9d83b83df9fbc75ecd754264f95793fca93ccf93 under
http://server.name/gitproject.git
Cannot obtain needed object 9d83b83df9fbc75ecd754264f95793fca93ccf93

What I'm doing wrong? Any ideas are welcome. Thanks.

Next: Jeff King
Message 1 of 3 in “Error in creating git over http”
  1. Shlomit AfginOct 8, 2013
  2. Jeff KingOct 10, 2013
  3. Shlomit AfginOct 10, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.