]> git.xonotic.org Git - xonotic/xonotic.git/commitdiff
apache config
authorRudolf Polzer <divverent@alientrap.org>
Tue, 21 Feb 2012 13:18:14 +0000 (14:18 +0100)
committerRudolf Polzer <divverent@alientrap.org>
Tue, 21 Feb 2012 13:18:14 +0000 (14:18 +0100)
misc/infrastructure/git-vhost.conf [new file with mode: 0644]

diff --git a/misc/infrastructure/git-vhost.conf b/misc/infrastructure/git-vhost.conf
new file mode 100644 (file)
index 0000000..771c80d
--- /dev/null
@@ -0,0 +1,53 @@
+<VirtualHost *:80>
+       ServerName de.git.xonotic.org
+       ServerAlias nl.git.xonotic.org
+       ServerAlias us.git.xonotic.org
+       ServerAlias git.xonotic.org
+       ServerAdmin divVerent@xonotic.org
+
+       SetEnv GIT_PROJECT_ROOT /var/cache/git
+
+       AliasMatch ^/(.*/objects/[0-9a-f]{2}/[0-9a-f]{38})$          /var/cache/git/$1
+       AliasMatch ^/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$ /var/cache/git/$1
+       ScriptAliasMatch \
+              "(?x)^/(.*/(HEAD | \
+                              info/refs | \
+                              objects/info/[^/]+ | \
+                              git-(upload|receive)-pack))$" \
+              /usr/lib/git-core/git-http-backend/$1
+
+       DocumentRoot /usr/share/gitweb
+       Alias /gitweb /usr/share/gitweb/static
+       DirectoryIndex gitweb.cgi
+
+       <Directory /usr/lib/git-core>
+               <Files git-http-backend>
+                       Allow from all
+                       Deny from none
+                       Order Allow,Deny
+
+                       Options +ExecCGI
+                       SetHandler cgi-script
+               </Files>
+       </Directory>
+
+       <Directory /var/cache/git>
+               Allow from all
+               Deny from none
+               Order Allow,Deny
+
+               Options Indexes
+       </Directory>
+
+       <Directory /usr/share/gitweb>
+               Allow from all
+               Deny from none
+               Order Allow,Deny
+
+               Options Indexes
+               <Files gitweb.cgi>
+                       Options +ExecCGI
+                       SetHandler cgi-script
+               </Files>
+       </Directory>
+</VirtualHost>