diff options
Diffstat (limited to 'manifests')
-rw-r--r-- | manifests/site.pp | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/manifests/site.pp b/manifests/site.pp index e2338d1..1fca9eb 100644 --- a/manifests/site.pp +++ b/manifests/site.pp @@ -365,7 +365,23 @@ node 'hornquist.se' { }.join("\n") } - nginx::resource::location { '~ \.git(/.*)': + nginx::resource::location { + $cgit::public_repos.map |$repo| { "~ ^(/${repo}\\.git/.*)" }: + server => 'cgit', + ssl_only => true, + priority => 450, + fastcgi => 'unix:/run/fcgiwrap.socket', + fastcgi_params => 'fastcgi_params', + fastcgi_param => { + 'SCRIPT_FILENAME' => '/usr/lib/git-core/git-http-backend', + 'GIT_PROJECT_ROOT' => '/home/git/git', + 'GIT_HTTP_EXPORT_ALL' => '""', + 'PATH_INFO' => '$1', + } + } + + + nginx::resource::location { '~ (.*\.git/.*)': server => 'cgit', ssl_only => true, location_cfg_append => { |