Note that there are some explanatory texts on larger screens.

plurals
  1. POGitolite and http Error 500. Permission issue in setup
    text
    copied!<p>I attempted to install Gitolite on a Fedora 17 server with the aim of setting up git and HTTP access along with authorisation. Git access works OK. Can push and pull. But HTTP access falls over with an Error 500. It appears I got something wrong with permissions. </p> <p>Here's what I did. I followed instructions from here: <code>sitaramc.github.com</code></p> <p>I <a href="http://mochapenguin.blogspot.co.uk/2013/02/setting-up-gitolite-git-and-http-access.html" rel="nofollow noreferrer">have documented what I have tried to do here</a> if anyone would like to see it down to detail.</p> <p>HTTP Error:</p> <blockquote> <p>Internal Server Error - 500<br> The server encountered an internal error or misconfiguration and was unable to complete your request.<br> More information about this error may be available in the server error log.</p> </blockquote> <p>Error Log - /var/log/httpd/error-git.log </p> <blockquote> <p>[Wed Feb 13 08:26:11 2013] [error] [client 192.168.0.40] suexec failure: could not open log file<br/> [Wed Feb 13 08:26:11 2013] [error] [client 192.168.0.40] fopen: Permission denied<br/> [Wed Feb 13 08:26:11 2013] [error] [client 192.168.0.40] Premature end of script headers: gitolite-suexec-wrapper.sh<br/> [Wed Feb 13 08:30:13 2013] [error] [client 192.168.0.40] Directory index forbidden by Options directive: /var/www/git/<br/></p> </blockquote> <p><strong>* Update 1 *</strong><br> - Managed to post the error output here.</p> <p><strong>* Update 2 *</strong><br> Relaxed permissions on log directory and gitolite-suexec-wrapper.sh. More details are available at the link above where I have documented in detail.<br> /var/log/httpd/error-git.log </p> <blockquote> <p>[Wed Feb 13 21:18:47 2013] [error] [client 192.168.0.40] suexec policy violation: see suexec log for more details<br> [Wed Feb 13 21:18:47 2013] [error] [client 192.168.0.40] Premature end of script headers: gitolite-suexec-wrapper.sh<br> [Wed Feb 13 21:18:54 2013] [error] [client 192.168.0.40] Directory index forbidden by Options directive: /var/www/git/ </p> <p>$ sudo more /var/log/httpd/suexec.log<br/> [2013-02-13 21:18:47]: uid: (990/git) gid: (988/git) cmd: gitolite-suexec-wrapper.sh<br/> [2013-02-13 21:18:47]: cannot stat program: (gitolite-suexec-wrapper.sh) </p> </blockquote> <p>Not sure where next</p> <p><strong>* Update 3 *</strong> </p> <p>Ok, so I made some progress. I may have fixed the permissions issue. Now facing a PATH issue. Like before, most relevant output is included here. Full details are updated at the link in my original post.</p> <p>My knowledge of Apache config is very basic. After reading about suEXEC, I realised the permission issue could be arising out of SELinux. So I disabled it for now. (Would like to identify a way of having gitolite working with SELinux active, but that's for later. Suggestions are welcome.)</p> <p>Now when I access the url: http:// mochapenguin /git/testing.git in browser</p> <p>001E# service=git-upload-pack 0000003BERR FATAL: unknown git/gitolite command: 'testing.git'</p> <p>When I test from the client machine, I see:</p> <blockquote> <p>ssh git@mochapenguin \echo $PATH FATAL: unknown git/gitolite command: 'echo /usr/lib64/qt-3.3/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/home/mochapenguin/.local/bin:/home/mochapenguin/bin'</p> </blockquote> <p><strong>* Update 4 *</strong><br> Alright, got it working. No further change was needed since my last update.</p> <p>I ought to have tried accessing the repo like so, instead of trying the URL in the browser:</p> <pre><code>git clone http://username:password@mochapenguin/git/testing.git </code></pre> <p>This setup allows clone and push over http</p> <p>I can't figure out what I got wrong.</p> <p>Could someone point me the right way, please?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload