2

I had installed arch with gitolite on my rapsberry 3. Actually everything works quite perfect. However I did this with this instruction: https://wiki.archlinux.org/index.php/gitolite

So I want to get access with HTTP on my repositories, but it didn't work very well. After I try:

git clone http://machine/git/test.git

The login prompt appears but at the end I got the following error message:

fatal: repository 'http://test:test@machine/git/test.git/' not found

Here is my wrapper script and my vhost configuration:

#!/usr/bin/bash
#
# suEXEC wrapper for gitolite-shell
#

export GIT_PROJECT_ROOT=/var/lib/gitolite/repositories
export GITOLITE_HTTP_HOME=/var/lib/gitolite

exec /usr/lib/gitolite/gitolite-shell

Vhost

<VirtualHost *:80>
    ServerName        machine
    ServerAlias       machine 
    ServerAdmin       server@machine

    DocumentRoot /srv/http/git/cgi-bin

    SuexecUserGroup gitolite gitolite
    ScriptAlias /git /srv/http/git/cgi-bin/gitolite-suexec-wrapper/
<Directory /srv/http/git/cgi-bin>
    Require all granted
    Options       None
    AllowOverride none
    Order         allow,deny
    Allow         from all
</Directory>

<Location /git>
    AuthType Basic
    AuthName "Git Access"
    AuthBasicProvider file
    AuthUserFile /srv/http/git/htpasswd
    Require valid-user
</Location>
</VirtualHost>

It works easily over ssh. Thanks for help or an any :)

EDIT

Error Log

fe80::ba27:ebff:fee8:6d83 - - [29/Apr/2017:01:36:20 +0200] "GET /git/test/info/refs?service=git-upload-pack HTTP/1.1" 401 1214
fe80::ba27:ebff:fee8:6d83 - - [29/Apr/2017:01:36:20 +0200] "GET /git/test/info/refs?service=git-upload-pack HTTP/1.1" 404 969
192.168.178.62 - - [29/Apr/2017:09:41:39 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 401 1218
192.168.178.62 - - [29/Apr/2017:09:41:39 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 404 969
192.168.178.62 - - [29/Apr/2017:09:45:45 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 401 1218
192.168.178.62 - - [29/Apr/2017:09:45:45 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 404 969
192.168.178.62 - - [29/Apr/2017:15:35:54 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 401 1218
192.168.178.62 - - [29/Apr/2017:15:35:54 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 404 969
192.168.178.62 - - [29/Apr/2017:15:36:49 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 401 1218
192.168.178.62 - - [29/Apr/2017:15:36:49 +0200] "GET /git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 404 969

Access Log

AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using fe80::ba27:ebff:fee8:6d83. Set the 'ServerName' directive globally to suppress this message
[Sat Apr 29 09:41:15.492040 2017] [mpm_event:notice] [pid 1138:tid 1996451408] AH00489: Apache/2.4.25 (Unix) configured -- resuming normal operations
[Sat Apr 29 09:41:15.492273 2017] [core:notice] [pid 1138:tid 1996451408] AH00094: Command line: '/usr/bin/httpd -D FOREGROUND'
[Sat Apr 29 09:44:06.533189 2017] [mpm_event:notice] [pid 1138:tid 1996451408] AH00491: caught SIGTERM, shutting down
[Sat Apr 29 09:45:43.788696 2017] [suexec:notice] [pid 1247:tid 1996410448] AH01232: suEXEC mechanism enabled (wrapper: /usr/bin/suexec)
AH00112: Warning: DocumentRoot [/etc/httpd/docs/dummy-host.example.com] does not exist
AH00112: Warning: DocumentRoot [/etc/httpd/docs/dummy-host2.example.com] does not exist
AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using fe80::ba27:ebff:fee8:6d83. Set the 'ServerName' directive globally to suppress this message
[Sat Apr 29 09:45:43.829445 2017] [mpm_event:notice] [pid 1247:tid 1996410448] AH00489: Apache/2.4.25 (Unix) configured -- resuming normal operations
[Sat Apr 29 09:45:43.829684 2017] [core:notice] [pid 1247:tid 1996410448] AH00094: Command line: '/usr/bin/httpd -D FOREGROUND'
funilrys
  • 787
  • 9
  • 20
ToyRobotic
  • 557
  • 10
  • 30
  • Does apache user has access over gitolite dir? Check server logs for errors? – hjpotter92 Apr 29 '17 at 11:07
  • It looks like that apache has no rights for it. – ToyRobotic Apr 29 '17 at 13:44
  • Try going over the few links mentioned in my question here: http://stackoverflow.com/q/42171560/1190388 Also check if your application is logging SUExec's logs in a different file (generally it is `suexec_log`). – hjpotter92 Apr 29 '17 at 14:18

0 Answers0