aboutsummaryrefslogtreecommitdiff
path: root/nginx
diff options
context:
space:
mode:
Diffstat (limited to 'nginx')
-rw-r--r--nginx/conf.d/default.conf13
1 files changed, 13 insertions, 0 deletions
diff --git a/nginx/conf.d/default.conf b/nginx/conf.d/default.conf
index 8ee8bcc..b991022 100644
--- a/nginx/conf.d/default.conf
+++ b/nginx/conf.d/default.conf
@@ -12,6 +12,19 @@ server {
expires 30d;
}
+ location ~ /.+/(info/refs|git-upload-pack) {
+ include fastcgi_params;
+ fastcgi_param SCRIPT_FILENAME /usr/libexec/git-core/git-http-backend;
+ fastcgi_param PATH_INFO $uri;
+ fastcgi_param GIT_HTTP_EXPORT_ALL 1;
+ fastcgi_param GIT_PROJECT_ROOT /srv/git;
+ fastcgi_param GIT_CONFIG_COUNT 1;
+ fastcgi_param GIT_CONFIG_KEY_0 safe.directory;
+ fastcgi_param GIT_CONFIG_VALUE_0 *;
+ fastcgi_param HOME /srv/git;
+ fastcgi_pass unix:/var/run/fcgiwrap.sock;
+ }
+
location @cgit {
include /etc/nginx/fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root/cgit.cgi;