Cgit Apache2 clean url configuration

larsh at larsh at
Thu Jul 21 12:39:02 CEST 2011

On Mon, Jul 18, 2011 at 11:59:16AM +0200, Jerry Jacobs wrote:
> It is very pleasant for documentation purposes to have clean urls, I 
> found on the web a apache2 configuration which should be added to the 
> cgit distribution for people who run apache and just copy-paste the 
> configuration:
> # cgit setup for Apache that results in completely clean URLs, ie.
> # visiting will produce the cgit index page
> <VirtualHost *>
> 	# this part is stand fare
> 	ServerName
> 	DocumentRoot /var/www/htdocs/cgit/
> 	<Directory "/var/www/htdocs/cgit/">
> 		AllowOverride None
> 		Options ExecCGI
> 		Order allow,deny
> 		Allow from all
> 	</Directory>
> 	# this part is the magic
> 	Alias /cgit.png /var/www/htdocs/cgit/cgit.png
> 	Alias /cgit.css /var/www/htdocs/cgit/cgit.css
> 	Alias / /var/www/htdocs/cgit/cgit.cgi/
> </VirtualHost>

Thanks. Could you wrap this up in a nice patch for README, maybe also
showing how to get similar behaviour without a special subdomain?


More information about the CGit mailing list