Skip to content

Instantly share code, notes, and snippets.

@alanbriolat
Created October 3, 2011 15:38
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save alanbriolat/1259389 to your computer and use it in GitHub Desktop.
Save alanbriolat/1259389 to your computer and use it in GitHub Desktop.
fcgiwrap setup for gitweb + gitolite
; Spawn fcgiwrap as the user owning the git repositories, with a socket writeable by nginx
[fcgi-program:fcgiwrap_gitolite]
command = /usr/sbin/fcgiwrap
user = gitolite
socket = unix:///var/run/supervisor/%(program_name)s.sock
socket_owner = gitolite:nginx
socket_mode = 0770
# nginx configuration for gitweb
server {
listen 80;
server_name git.hexi.co;
location / {
root /usr/share/gitweb;
index index.cgi;
include fastcgi_params;
gzip off;
if ($uri ~ "/index.cgi") {
fastcgi_pass unix:/var/run/supervisor/fcgiwrap_gitolite.sock;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment