Scope vars for apache template

The variables we use from the phabricator class should get the
right scope in the template or they won't work properly.
This commit is contained in:
stephane 2015-04-01 18:56:44 -07:00
parent ad46be7758
commit 6ffd68ae30
1 changed files with 7 additions and 7 deletions

View File

@ -1,6 +1,6 @@
<VirtualHost *:80> <VirtualHost *:80>
ServerAdmin noc@openstack.org ServerAdmin noc@openstack.org
ServerName <%= @vhost_name %> ServerName <%= scope.lookupvar("phabricator::vhost_name") %>
DocumentRoot /var/www DocumentRoot /var/www
<Directory /> <Directory />
@ -16,7 +16,7 @@
RewriteEngine on RewriteEngine on
RewriteCond %{SERVER_PORT} !^443$ RewriteCond %{SERVER_PORT} !^443$
RewriteRule ^/(.*)$ https://<%= @vhost_name %>/$1 [L,R] RewriteRule ^/(.*)$ https://<%= scope.lookupvar("phabricator::vhost_name") %>/$1 [L,R]
ErrorLog /var/log/apache2/phabricator-error.log ErrorLog /var/log/apache2/phabricator-error.log
@ -30,14 +30,14 @@
</VirtualHost> </VirtualHost>
<VirtualHost *:443> <VirtualHost *:443>
ServerAdmin noc@openstack.org ServerAdmin noc@openstack.org
ServerName <%= @vhost_name %> ServerName <%= scope.lookupvar("phabricator::vhost_name") %>
SSLEngine on SSLEngine on
SSLProtocol All -SSLv2 -SSLv3 SSLProtocol All -SSLv2 -SSLv3
SSLCertificateFile <%= @ssl_cert_file %> SSLCertificateFile <%= scope.lookupvar("phabricator::ssl_cert_file") %>
SSLCertificateKeyFile <%= @ssl_key_file %> SSLCertificateKeyFile <%= scope.lookupvar("phabricator::ssl_key_file") %>
<% if @ssl_chain_file != "" %> <% if scope.lookupvar("phabricator::ssl_chain_file") != "" %>
SSLCertificateChainFile <%= @ssl_chain_file %> SSLCertificateChainFile <%= scope.lookupvar("phabricator::ssl_chain_file") %>
<% end %> <% end %>
DocumentRoot <%= @docroot %> DocumentRoot <%= @docroot %>