Created
August 3, 2012 18:39
-
-
Save lancechentw/3250315 to your computer and use it in GitHub Desktop.
apache config for git smart http with ldap auth
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
ServerName your.domain.name | |
DocumentRoot /srv/http | |
setEnv GIT_PROJECT_ROOT /opt/git | |
setEnv GIT_HTTP_EXPORT_ALL | |
scriptAlias /git/ /usr/lib/git-core/git-http-backend/ | |
<Directory /> | |
Order allow,deny | |
Allow from all | |
</Directory> | |
<LocationMatch "/git/"> | |
AuthName "GIT" | |
AuthType Basic | |
AuthBasicProvider ldap | |
AuthzLDAPAuthoritative off | |
AuthLDAPURL "ldaps://your.ldap.server/ou=People,dc=cs,dc=nctu,dc=edu,dc=tw" | |
Require valid-user | |
</LocationMatch> | |
</VirtualHost> | |
LDAPVerifyServerCert off |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment