You are not logged in.

#1 2012-05-05 21:30:32

Hibernate
Member
From: Stockholm, Sweden
Registered: 2011-07-12
Posts: 100

Can't start git-daemon

Git server stuff requires invocation of git-daemon, but when I type

git-daemon

I get the response

bash: git-daemon: command not found

When I try to start git-daemon by typing

sudo /etc/rc.d/git-daemon start

I get the response

:: Starting git-daemon daemon    [FAIL]

git-daemon is stopped as told by both

sudo /etc/rc.d/git-daemon status

and

rc.d list

Of course I have git installed, and putting git-daemon under DAEMONS in rc.conf and rebooting does not help.

Offline

#2 2012-05-05 21:55:09

guelfi
Member
From: /home/guelfi
Registered: 2011-07-01
Posts: 111

Re: Can't start git-daemon

Hibernate wrote:

Git server stuff requires invocation of git-daemon, but when I type

git-daemon

I get the response

bash: git-daemon: command not found
man git-daemon wrote:
SYNPOSIS
    git daemon [...]

Last edited by guelfi (2012-05-05 21:55:54)

Offline

#3 2012-05-05 22:07:35

Hibernate
Member
From: Stockholm, Sweden
Registered: 2011-07-12
Posts: 100

Re: Can't start git-daemon

git daemon

just starts program that does nothing,
the wiki entry on gitosis says you should invoke

sudo -u git git-daemon --base-path=/srv/gitosis/repositories/ --export-all

Offline

#4 2012-05-05 22:17:46

guelfi
Member
From: /home/guelfi
Registered: 2011-07-01
Posts: 111

Re: Can't start git-daemon

Hibernate wrote:

the wiki entry on gitosis says you should invoke

sudo -u git git-daemon --base-path=/srv/gitosis/repositories/ --export-all

Well, the wiki entry on gitosis is, apparently, wrong. As you can see yourself, there is no binary named git-daemon in your PATH.
If you look into the init script you are trying to run (/etc/rc.d/git-daemon), you will see that it executes /usr/lib/git-core/git-daemon.

Hibernate wrote:
git daemon

just starts program that does nothing,

Of course it does nothing right away - it's a daemon, and while it's running, it should serve git repos if you request them from another host.

Last edited by guelfi (2012-05-05 22:18:42)

Offline

#5 2012-05-05 23:31:39

Hibernate
Member
From: Stockholm, Sweden
Registered: 2011-07-12
Posts: 100

Re: Can't start git-daemon

sudo -u git git daemon --base-path=/srv/gitosis/repositories/ --export-all

Does nothing either, other pages on the Internet, also use git-daemon.

But /etc/rc.d/git-daemon fails to start that should not happen, right.

Offline

#6 2012-05-06 09:09:57

guelfi
Member
From: /home/guelfi
Registered: 2011-07-01
Posts: 111

Re: Can't start git-daemon

Did you put the right repo in /etc/git-daemon.conf? For me, it works if I create /srv/git which is the default repo path.

Other pages on the internet using git-daemon doesn't make using git-daemon correct. Maybe Arch packages git differently than other distros and doesn't put git-daemon into the PATH.

On the "'git daemon' does nothing"-thing: If you knew what you are doing right now, you wouldn't expect "git daemon" to do anything on the console. Are you even familiar with the concept of a daemon?
If not, give this a read.

Offline

#7 2012-05-06 10:59:10

Hibernate
Member
From: Stockholm, Sweden
Registered: 2011-07-12
Posts: 100

Re: Can't start git-daemon

/etc/conf.d/git-daemon.conf contains

GIT_REPO="/srv/git/"
GIT_DAEMON_ARGS="--detach --syslog --verbose --base-path=$GIT_REPO $GIT_REPO"

I know that I daemon is, but since I'm told to invoke git-daemon (or git daemon) I expect
the started program to at least exit.

Offline

#8 2012-05-12 18:04:30

Hibernate
Member
From: Stockholm, Sweden
Registered: 2011-07-12
Posts: 100

Re: Can't start git-daemon

bump

Offline

#9 2012-05-13 09:14:56

guelfi
Member
From: /home/guelfi
Registered: 2011-07-01
Posts: 111

Re: Can't start git-daemon

Why did you bump this thread? Do you still have any issue?

Offline

#10 2012-05-13 14:30:06

Hibernate
Member
From: Stockholm, Sweden
Registered: 2011-07-12
Posts: 100

Re: Can't start git-daemon

Yes, git-daemon files to start, both by
sudo /etc/rc.d/git-daemon start
and at boot when listed in rc.conf DAEMONS.

Offline

Board footer

Powered by FluxBB