Gitosis+GitWeb on Gentoo
Jan. 30th, 2008 02:11 am![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Following up on the previous post about Gitosis on Gentoo, here's how to integrate GitWeb into the config.
You should emerge dev-util/git with USE="cgi perl", and then dump the following two bits of config in.
The following is /etc/git/config.pl
$feature{'blame'}{'default'} = [1]; $feature{'blame'}{'override'} = 1; $feature{'pickaxe'}{'default'} = [1]; $feature{'pickaxe'}{'override'} = 1; $feature{'search'}{'default'} = [1]; $feature{'search'}{'override'} = 1; $feature{'grep'}{'default'} = [1]; $feature{'grep'}{'override'} = 1; $feature{'snapshot'}{'default'} = ['tgz', 'tbz2', 'zip']; $feature{'snapshot'}{'override'} = 1; $projectroot = '/var/gitroot/'; $site_name = "Gentoo Linux Overlays-Git"; $fallback_encoding = 'utf-8'; # These lock it down $projects_list = '/var/spool/gitosis/gitosis/projects.list'; # Don't enable these #$export_ok = 1; #$strict_export = 1; # This lets it make the URLs you see in the header @git_base_url_list = ( 'git://git.overlays.gentoo.org', 'git+ssh://git@git.overlays.gentoo.org' ); # Title $home_link_str = 'overlays';So that GitWeb can find this, we have the following chunk in an apache vhost.
Alias /gitweb/ /usr/share/git/gitweb/ <Directory "/usr/share/git/gitweb/"> AllowOverride AuthConfig Options +ExecCGI +Indexes Order allow,deny Allow from all DirectoryIndex gitweb.cgi SetEnv GITWEB_CONFIG "/etc/git/config.pl" AddHandler cgi-script .cgi </Directory>