
In anticipation of puppet 4, start trying to deal with puppet 4 things that can be helpfully predicted by puppet lint plugins. This patch also corrects lint errors caught by the puppet-lint-absolute_classname-check and puppet-lint-empty_string-check gems as well as arrow alignment which wasn't being caught under the system version of puppet-lint. Change-Id: I7b9efb0fce3b59d611aa9aaaf6899bc6e6cc62b0
78 lines
2.6 KiB
Plaintext
78 lines
2.6 KiB
Plaintext
<VirtualHost *:<%= scope.lookupvar("cgit::http_port") %>>
|
|
ServerName <%= scope.lookupvar("cgit::vhost_name") %>
|
|
ServerAdmin <%= scope.lookupvar("cgit::serveradmin") %>
|
|
|
|
<% if @serveraliases.is_a? Array -%>
|
|
<% @serveraliases.each do |name| -%><%= " ServerAlias #{name}\n" %><% end -%>
|
|
<% elsif @serveraliases != '' -%>
|
|
<%= " ServerAlias #{@serveraliases}" -%>
|
|
<% end -%>
|
|
|
|
Alias /cgit-data /usr/share/cgit
|
|
ScriptAlias /cgit /var/www/cgi-bin/cgit
|
|
Alias /static <%= scope.lookupvar("cgit::staticfiles") %>
|
|
RewriteEngine On
|
|
RewriteRule ^/$ /cgit [R]
|
|
|
|
SetEnv GIT_PROJECT_ROOT /var/lib/git/
|
|
SetEnv GIT_HTTP_EXPORT_ALL
|
|
SetEnv GIT_NOTES_DISPLAY_REF refs/notes/*
|
|
|
|
AliasMatch ^/(.*/objects/[0-9a-f]{2}/[0-9a-f]{38})$ /var/lib/git/$1
|
|
AliasMatch ^/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$ /var/lib/git/$1
|
|
ScriptAlias / /usr/libexec/git-core/git-http-backend/
|
|
|
|
ErrorLog /var/log/httpd/git-error.log
|
|
|
|
<% if scope.lookupvar("cgit::cgit_timeout").is_a? Integer %>
|
|
Timeout <%= scope.lookupvar("cgit::cgit_timeout") %>
|
|
<% end %>
|
|
|
|
LogLevel warn
|
|
|
|
CustomLog /var/log/httpd/git-access.log combined
|
|
</VirtualHost>
|
|
|
|
<VirtualHost *:<%= scope.lookupvar("cgit::https_port") %>>
|
|
ServerName <%= scope.lookupvar("cgit::vhost_name") %>
|
|
ServerAdmin <%= scope.lookupvar("cgit::serveradmin") %>
|
|
|
|
<% if @serveraliases.is_a? Array -%>
|
|
<% @serveraliases.each do |name| -%><%= " ServerAlias #{name}\n" %><% end -%>
|
|
<% elsif @serveraliases != '' -%>
|
|
<%= " ServerAlias #{@serveraliases}" -%>
|
|
<% end -%>
|
|
|
|
Alias /cgit-data /usr/share/cgit
|
|
ScriptAlias /cgit /var/www/cgi-bin/cgit
|
|
Alias /static <%= scope.lookupvar("cgit::staticfiles") %>
|
|
RewriteEngine On
|
|
RewriteRule ^/$ /cgit [R]
|
|
|
|
SetEnv GIT_PROJECT_ROOT /var/lib/git/
|
|
SetEnv GIT_HTTP_EXPORT_ALL
|
|
SetEnv GIT_NOTES_DISPLAY_REF refs/notes/*
|
|
|
|
AliasMatch ^/(.*/objects/[0-9a-f]{2}/[0-9a-f]{38})$ /var/lib/git/$1
|
|
AliasMatch ^/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$ /var/lib/git/$1
|
|
ScriptAlias / /usr/libexec/git-core/git-http-backend/
|
|
|
|
ErrorLog /var/log/httpd/git-error.log
|
|
|
|
LogLevel warn
|
|
|
|
CustomLog /var/log/httpd/git-access.log combined
|
|
|
|
SSLEngine on
|
|
SSLProtocol All -SSLv2 -SSLv3
|
|
|
|
SSLCertificateFile <%= scope.lookupvar("cgit::ssl_cert_file") %>
|
|
SSLCertificateKeyFile <%= scope.lookupvar("cgit::ssl_key_file") %>
|
|
<%# The original default was '' -%>
|
|
<%# scope.lookupvar returns nil for an undefined variable in puppet 4 -%>
|
|
<%# scope.lookupvar returns :undef for an undefined variable in puppet 3 -%>
|
|
<% unless ['', nil, :undef].include?(scope.lookupvar("cgit::ssl_chain_file")) %>
|
|
SSLCertificateChainFile <%= scope.lookupvar("cgit::ssl_chain_file") %>
|
|
<% end %>
|
|
</VirtualHost>
|