Cgit Apache2 clean url configuration

Jerry Jacobs jerkejacobs at
Mon Jul 18 11:59:16 CEST 2011

Dear All,

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 

# cgit setup for Apache that results in completely clean URLs, ie.
# visiting will produce the cgit index page
<VirtualHost *>
	# this part is stand fare
	DocumentRoot /var/www/htdocs/cgit/
	<Directory "/var/www/htdocs/cgit/">
		AllowOverride None
		Options ExecCGI
		Order allow,deny
		Allow from all
	# 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/

Kind regards,
Jerry Jacobs

More information about the CGit mailing list