Promote /ara-report/ middleware redirection to logs.openstack.org
We've successfully tested the ARA sqlite middleware on logs-dev.o.o. We're ready to use this on logs.openstack.org. Change-Id: I88c06366b8d5837ad6fc50163e5d58fe1b5eaa8f
This commit is contained in:
parent
8d373a8468
commit
8a826a0fd4
@ -78,6 +78,32 @@ NameVirtualHost <%= @vhost_name %>:<%= @port %>
|
||||
</Directory>
|
||||
|
||||
RewriteEngine On
|
||||
<% if @ara_middleware -%>
|
||||
<Directory "/usr/local/bin">
|
||||
<Files "ara-wsgi-sqlite">
|
||||
Allow from all
|
||||
Satisfy Any
|
||||
</Files>
|
||||
</Directory>
|
||||
# ARA sqlite middleware configuration
|
||||
# See docs for details: https://ara.readthedocs.io/en/latest/advanced.html
|
||||
SetEnv ARA_WSGI_TMPDIR_MAX_AGE <%= @ara_middleware_tmpdir_max_age %>
|
||||
SetEnv ARA_WSGI_LOG_ROOT <%= @docroot %>
|
||||
SetEnv ARA_WSGI_DATABASE_DIRECTORY <%= @ara_middleware_database_directory %>
|
||||
|
||||
# Redirect .*/<%= @ara_middleware_database_directory %> to the ARA sqlite wsgi middleware
|
||||
# This middleware automatically loads the ARA web application with the
|
||||
# database located at .*/<%= @ara_middleware_database_directory %>/ansible.sqlite.
|
||||
# If we get a request directly to the database file, don't load the middleware
|
||||
# so that users can download the raw database if they wish.
|
||||
WSGIScriptAliasMatch ^.*/<%= @ara_middleware_database_directory %>(?!/ansible.sqlite) /usr/local/bin/ara-wsgi-sqlite
|
||||
|
||||
# Everything beyond this point is rewritten to htmlify.
|
||||
# Make sure we don't do that for dynamic ARA reports.
|
||||
RewriteCond %{REQUEST_URI} ^.*/<%= @ara_middleware_database_directory %> [NC]
|
||||
RewriteRule .* - [L]
|
||||
<% end -%>
|
||||
|
||||
# If the specified file does not exist, look if there is a gzipped version
|
||||
# If there is, serve that one instead
|
||||
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_FILENAME} !-f
|
||||
|
Loading…
x
Reference in New Issue
Block a user