<%= node["openstack"]["dashboard"]["custom_template_banner"] %> :<%= @http_bind_port %>> <% if node["openstack"]["dashboard"]["server_hostname"] -%> ServerName <%= node["openstack"]["dashboard"]["server_hostname"] %> <% end -%> <% unless node["openstack"]["dashboard"]["server_aliases"].empty? -%> ServerAlias <%= node["openstack"]["dashboard"]["server_aliases"].join(" ") %> <% end -%> <% if node["openstack"]["dashboard"]["use_ssl"] %> RewriteEngine On RewriteCond %{HTTPS} off <% if @http_bind_port != 80 or @https_bind_port != 443 %> RewriteRule ^(.*)$ https://%{SERVER_NAME}:<%= @https_bind_port %>%{REQUEST_URI} [L,R] <% else -%> RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R] <% end -%> TraceEnable <%= node['openstack']['dashboard']['traceenable'] %> :<%= @https_bind_port %>> <% if node["openstack"]["dashboard"]["server_hostname"] -%> ServerName <%= node["openstack"]["dashboard"]["server_hostname"] %> <% end -%> <% unless node["openstack"]["dashboard"]["server_aliases"].empty? -%> ServerAlias <%= node["openstack"]["dashboard"]["server_aliases"].join(" ") %> <% end -%> <% end %> ServerAdmin <%= @apache_admin %> # Note(jr): This is needed when SSL is used for the services, see # https://bugs.launchpad.net/openstack-ansible/+bug/1624791/comments/17 WSGIApplicationGroup %{GLOBAL} WSGIScriptAlias <%= node["openstack"]["dashboard"]["webroot"] %> <%= node["openstack"]["dashboard"]["wsgi_path"] %> WSGIDaemonProcess dashboard user=<%= node['openstack']['dashboard']['horizon_user'] %> group=<%= node['openstack']['dashboard']['horizon_group'] %> processes=3 threads=10 python-path=<%= node["openstack"]["dashboard"]["dash_path"] %> WSGIProcessGroup dashboard DocumentRoot <%= node["openstack"]["dashboard"]["dash_path"] %>/.blackhole/ Alias /static <%= node["openstack"]["dashboard"]["static_path"] %> Options FollowSymLinks AllowOverride None > Options Indexes FollowSymLinks MultiViews AllowOverride None Require all granted > Options FollowSymLinks MultiViews AllowOverride None Require all granted <% if node["openstack"]["dashboard"]["use_ssl"] -%> SSLEngine on SSLCertificateFile <%= @ssl_cert_file %> SSLCertificateKeyFile <%= @ssl_key_file %> <% if node['openstack']['dashboard']['ssl']['chain'] -%> SSLCertificateChainFile <%= @ssl_chain_file %> <% end -%> SSLProtocol <%= node["openstack"]["dashboard"]["ssl"]["protocol"] %> <% if node["openstack"]["dashboard"]["ssl"]["ciphers"] -%> SSLCipherSuite <%= node["openstack"]["dashboard"]["ssl"]["ciphers"] %> <% end -%> <% end -%> # Allow custom files to overlay the site (such as logo.png) RewriteEngine On RewriteCond /opt/dash/site_overlay%{REQUEST_FILENAME} -s RewriteRule ^/(.+) /opt/dash/site_overlay/$1 [L] ErrorLog <%= @log_dir %>/<%= node["openstack"]["dashboard"]["error_log"] %> LogLevel warn CustomLog <%= @log_dir %>/<%= node["openstack"]["dashboard"]["access_log"] %> combined TraceEnable <%= node['openstack']['dashboard']['traceenable'] %> <% unless node["openstack"]["dashboard"]["cache_html"] %> SetEnvIfExpr "req('accept') =~/html/" NO_CACHE Header merge Cache-Control no-cache env=NO_CACHE Header merge Cache-Control no-store env=NO_CACHE <% end -%> <% unless node["openstack"]["dashboard"]["wsgi_socket_prefix"].nil? %> WSGISocketPrefix <%= node["openstack"]["dashboard"]["wsgi_socket_prefix"] %> <% end %>