First of all after much pain i figured out how to make it work in Apache 2.4 windowz. Here is my configuration that seems to work successfully for git clone and push and everything.

First of all my configuration works. There is a "Require all denied" at / directory. I want only git functionality and nothing else.

Example Request from a git client - - [07/Oct/2012:04:44:51 +0300] "GET /git/simple/info/refs?service=git-upload-pack HTTP/1.1" 200 264`

Error caused by that Request

[Sun Oct 07 04:44:51.903334 2012] [authz_core:error] [pid 6988:tid 956] [client] AH01630: client denied by server configuration: C:/git-server/web/simple

There isnt any error at gitclient everything works fine but i get this at error log. Is there any solution for this error to not appear?I worry about log size.

 <VirtualHost *:80>
    DocumentRoot  "C:\git-server\web"
    ServerName git.****censored****
    DirectoryIndex index.php

    SetEnv GIT_PROJECT_ROOT c:/git-server/repositories
    ScriptAlias /git/ "C:/Program Files (x86)/Git/libexec/git-core/git-http-backend.exe/"

    <LocationMatch "^/.*/git-receive-pack$">
        Options +ExecCGI
        AuthType Basic
        AuthName intranet
        AuthUserFile "C:/git-server/config/users"
        Require valid-user
    <Directory />
        Options All
        Require all denied
    <Directory  "C:\Program Files (x86)\Git\libexec\git-core">
        Options +ExecCGI
        Options All
        Require all granted


Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.