staging.git; --depth=1 doesn't seem to work with "smart http"
Bug #1253139 reported by
Paul Sokolovsky
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Linaro Infrastructure Misc |
Fix Released
|
Medium
|
Milo Casagrande |
Bug Description
Following up to meeting with Rob:
$ git clone http://
- works as expected
$ git clone --depth=1 http://
Cloning into 'gcc'...
fatal: The remote end hung up unexpectedly
fatal: protocol error: bad pack header
Changed in linaro-infrastructure-misc: | |
importance: | Undecided → Medium |
Changed in linaro-infrastructure-misc: | |
assignee: | nobody → Milo Casagrande (milo) |
Changed in linaro-infrastructure-misc: | |
milestone: | none → 2013.11 |
status: | New → In Progress |
Changed in linaro-infrastructure-misc: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
So, I took a look at this problem, and found out what's going on.
I'm not sure why it started to act like that: the only idea I have is that with recent version of git something changed in the way git commands are run, since previously a clone operation with --depth=1 was working.
From Apache log, when trying to clone a repository, we can find this:
fatal: Unable to create temporary file '/srv/repositor ies/lava/ lava-server. git/shallow_ zjbO0B' : Permission denied
fatal: The remote end hung up unexpectedly
Looking at the process table and their command line, this is the command that is run by git:
git --shallow-file shallow_NPYjEM pack-objects --revs --thin --stdout --progress --delta-base-offset
The repository directories under /srv/repositories on the server are set with the following access: rwxr-----, and are owned by git:git.
The process that runs git during a clone operation via smart HTTP is run under www-data, and www-data is part of the git group on the server, but does not have write access to the directories.
Just changing the permission on the directory solved the problem, and I was able to perform a clone operation.