Listen <%= @puppet_passenger_port %>

<VirtualHost *:<%= @puppet_passenger_port %>>
  ServerName <%= @puppet_site %>

  SSLProtocol -ALL +SSLv3 +TLSv1
  SSLCipherSuite ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:-LOW:-SSLv2:-EXP
  SSLVerifyClient         optional
  SSLVerifyDepth          1
  SSLOptions              +StdEnvVars

  RequestHeader unset X-Forwarded-For

  RequestHeader set X-SSL-Subject %{SSL_CLIENT_S_DN}e
  RequestHeader set X-Client-DN %{SSL_CLIENT_S_DN}e
  RequestHeader set X-Client-Verify %{SSL_CLIENT_VERIFY}e

  DocumentRoot <%= puppet_docroot %>
  RackBaseURI /
  <Directory /etc/puppet/rack/>
    Options None
    AllowOverride None
    Order allow,deny
    Allow from all
  </Directory>
<% if @puppet_central_ca -%>

  ProxyRequests Off
  <Proxy *>
    Order allow,deny
<% @proxy_allow_from.each do |host| -%>
    Allow from <%= host %>
<% end -%>
  </Proxy>

  ProxyVia On

  ProxyPassMatch ^/([^/]+/certificate.*)$ <%= @puppet_central_ca %>/$1
<% end -%>
</VirtualHost>



  SSLProtocol -ALL +SSLv3 +TLSv1
  SSLCipherSuite ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:-LOW:-SSLv2:-EXP
  SSLVerifyClient         optional
  SSLVerifyDepth          1
  SSLOptions              +StdEnvVars

  RequestHeader unset X-Forwarded-For

  RequestHeader set X-SSL-Subject %{SSL_CLIENT_S_DN}e
  RequestHeader set X-Client-DN %{SSL_CLIENT_S_DN}e
  RequestHeader set X-Client-Verify %{SSL_CLIENT_VERIFY}e

  RackBaseURI /
  <Directory /etc/puppet/rack/>
    Options None
    AllowOverride None
    Order allow,deny
    Allow from all
  </Directory>
<% if @puppet_central_ca -%>

  ProxyRequests Off
  <Proxy *>
    Order allow,deny
<% @proxy_allow_from.each do |host| -%>
    Allow from <%= host %>
<% end -%>
  </Proxy>

  ProxyVia On

  ProxyPassMatch ^/([^/]+/certificate.*)$ <%= @puppet_central_ca %>/$1
<% end -%>


Remove servername, listen, documentroot directives and virtual host declerations.
Remove servername, listen, documentroot directives and virtual host
declerations.