apt-get install lighttpd gitweb git-core
Then add a lighttpd configuration file.
server.modules += ( "mod_cgi" )
url.redirect = ( "^/git$" => "/git/" )
alias.url += ( "/git/" => "/usr/lib/cgi-bin/" )
$HTTP["url"] =~ "^/git/" {
cgi.assign = ( ".cgi" => "" )
index-file.names = ( "gitweb.cgi" )
}
Wrote this in /etc/lighttpd/conf-available/10-gitweb.conf.
The copy the three files in /usr/share/gitweb in /var/www.
Now edit projectroot field in your gitweb configuration file in /etc/gitweb.conf:
$projectroot = "/your/directory/git";
Save /etc/gitweb.conf and enable gitweb configuration for lighttpd:
lighttpd-enable-mod gitweb
invoke-rc.d lighttpd force-reload
Nessun commento:
Posta un commento