# Problem with post-receive hook

1 messages from 2008-02-01 to 2008-02-01. Participants: Bill Lear.
Thread: https://gitlist.dev/t/11815

## Bill Lear, 2008-02-01 19:01

Subject: Problem with post-receive hook
Message-ID: <18339.27767.633833.374795@lisa.zopyra.com>
URL: https://gitlist.dev/e/18339.27767.633833.374795%40lisa.zopyra.com

```
I am having trouble getting the contributed post-receive hook to work,
which worked just fine the last time I tried it.  I am using the
latest code from the git repo directly and have also tried the 1.5.3.8
version.

I am running the git-daemon through xinetd, and it is configured
like so:

% cat /etc/xinetd.d/git-daemon
# description: The git server offers access to git repositories
service git
{
        disable         = no
        type            = UNLISTED
        port            = 9418
        socket_type     = stream
        wait            = no
        user            = rael
        server          = /opt/git/bin/git-daemon
        server_args     = --enable=receive-pack --verbose --syslog --inetd --export-all --base-path=/repos/git
        log_on_failure  += USERID
}

I have a test repo in /repos/git/fun, and I can clone it, and push
to it successfully.  I have configured the config file in /repos/git/fun
like so:

% cat /repos/git/fun/config
[core]
        repositoryformatversion = 0
        filemode = true
        bare = true
        legacyheaders = false
        logallrefupdates = true
[repack]
        usedeltabaseoffset = true
[hooks]
        mailinglist = rael@zopyra.com

and have ensured that the hook /repos/git/config/fun/hooks/post-receive
is executable.

I have run it from the command line and it has printed out what I
expected it to, but for some reason when the git daemon gets a pack,
it does not seem to execute the hook.  I have looked through the git
daemon code in daemon.c, and the receive-pack code, and I see nothing
obvious that has changed since the last time I looked at it.

I have verified that the git daemon works to upload the packs (I push
changes, go somewhere else, clone and the changes are there; also, it
shows the upload in the syslog file /var/log/messages), and I'm just
at a loss.  The message file says, for example:

Feb  1 11:25:47 zopyra git-daemon: [31240] Connection from 192.168.10.23:41527
Feb  1 11:25:47 zopyra git-daemon: [31240] Extended attributes (12 bytes) exist <host=zopyra>
Feb  1 11:25:47 zopyra git-daemon: [31240] Request upload-pack for '/fun'
Feb  1 11:25:47 zopyra xinetd[2382]: EXIT: git status=0 pid=31240 duration=0(sec)

so, nothing seems amiss here.

Have I missed something really stupid?


Bill

```
