Merge "Allow specification of locations to not be proxied"

This commit is contained in:
Jenkins 2015-10-06 07:27:48 +00:00 committed by Gerrit Code Review
commit 2a142ac027
2 changed files with 8 additions and 1 deletions

View File

@ -26,7 +26,8 @@ define httpd::vhost::proxy (
$servername = undef,
$serveraliases = undef,
$ssl = false,
$vhost_name = '*'
$vhost_name = '*',
$proxyexclusions = undef,
) {
include ::httpd

View File

@ -16,6 +16,12 @@ NameVirtualHost <%= @vhost_name %>:<%= @port %>
Order deny,allow
Allow from all
</Proxy>
<% if @proxyexclusions.is_a? Array %>
<% @proxyexclusions.each do |name| %><%= " ProxyPass #{name} !\n" %><% end %>
<% elsif @proxyexclusions != nil %>
<%= " ProxyPass #{@proxyexclusions} !" %>
<% end %>
ProxyPass / <%= @dest %>/
ProxyPassReverse / <%= @dest %>/
ProxyPreserveHost On