diff --git a/manifests/logserver.pp b/manifests/logserver.pp
index dc897f0..6259a37 100644
--- a/manifests/logserver.pp
+++ b/manifests/logserver.pp
@@ -24,6 +24,8 @@ class openstackci::logserver (
$swift_tenant_name = '',
$swift_region_name = '',
$swift_default_container = '',
+ $legacy = true,
+ $readmes = [],
) {
if ! defined(Class['::jenkins::jenkinsuser']) {
@@ -177,37 +179,39 @@ class openstackci::logserver (
require => File['/etc/os_loganalyze'],
}
- vcsrepo { '/opt/devstack-gate':
- ensure => latest,
- provider => git,
- revision => 'master',
- source => 'https://git.openstack.org/openstack-infra/devstack-gate',
- }
+ if $legacy {
+ vcsrepo { '/opt/devstack-gate':
+ ensure => latest,
+ provider => git,
+ revision => 'master',
+ source => 'https://git.openstack.org/openstack-infra/devstack-gate',
+ }
- file { '/srv/static/logs/help':
- ensure => directory,
- owner => 'root',
- group => 'root',
- mode => '0755',
- require => File['/srv/static/logs'],
- }
+ file { '/srv/static/logs/help':
+ ensure => directory,
+ owner => 'root',
+ group => 'root',
+ mode => '0755',
+ require => File['/srv/static/logs'],
+ }
- file { '/srv/static/logs/help/tempest-logs.html':
- ensure => present,
- owner => 'root',
- group => 'root',
- mode => '0444',
- source => 'file:///opt/devstack-gate/help/tempest-logs.html',
- require => [File['/srv/static/logs/help'], Vcsrepo['/opt/devstack-gate']],
- }
+ file { '/srv/static/logs/help/tempest-logs.html':
+ ensure => present,
+ owner => 'root',
+ group => 'root',
+ mode => '0444',
+ source => 'file:///opt/devstack-gate/help/tempest-logs.html',
+ require => [File['/srv/static/logs/help'], Vcsrepo['/opt/devstack-gate']],
+ }
- file { '/srv/static/logs/help/tempest-overview.html':
- ensure => present,
- owner => 'root',
- group => 'root',
- mode => '0444',
- source => 'file:///opt/devstack-gate/help/tempest-overview.html',
- require => [File['/srv/static/logs/help'], Vcsrepo['/opt/devstack-gate']],
+ file { '/srv/static/logs/help/tempest-overview.html':
+ ensure => present,
+ owner => 'root',
+ group => 'root',
+ mode => '0444',
+ source => 'file:///opt/devstack-gate/help/tempest-overview.html',
+ require => [File['/srv/static/logs/help'], Vcsrepo['/opt/devstack-gate']],
+ }
}
file { '/usr/local/sbin/log_archive_maintenance.sh':
diff --git a/templates/logs-dev.vhost.erb b/templates/logs-dev.vhost.erb
index 4579938..6a0ef77 100644
--- a/templates/logs-dev.vhost.erb
+++ b/templates/logs-dev.vhost.erb
@@ -53,18 +53,11 @@ NameVirtualHost <%= @vhost_name %>:<%= @port %>
Satisfy Any
- /*/*/*/*/*-tempest-dsvm*/*>
- ReadmeName /help/tempest-overview.html
-
- /periodic*/*/*-tempest-dsvm*/*>
- ReadmeName /help/tempest-overview.html
-
- /*/*/*/*/*-tempest-dsvm*/*/logs/>
- ReadmeName /help/tempest-logs.html
-
- /periodic*/*/*-tempest-dsvm*/*/logs/>
- ReadmeName /help/tempest-logs.html
+<% @readmes.each do |pattern| -%>
+ <%= pattern %>>
+ ReadmeName <%= @readmes[pattern] %>
+<% end -%>
RewriteEngine On
# If the specified file does not exist, look if there is a gzipped version
diff --git a/templates/logs.vhost.erb b/templates/logs.vhost.erb
index c4e280c..bb5e846 100644
--- a/templates/logs.vhost.erb
+++ b/templates/logs.vhost.erb
@@ -67,18 +67,11 @@ NameVirtualHost <%= @vhost_name %>:<%= @port %>
Satisfy Any
- /*/*/*/*/*-tempest-dsvm*/*>
- ReadmeName /help/tempest-overview.html
-
- /periodic*/*/*-tempest-dsvm*/*>
- ReadmeName /help/tempest-overview.html
-
- /*/*/*/*/*-tempest-dsvm*/*/logs/>
- ReadmeName /help/tempest-logs.html
-
- /periodic*/*/*-tempest-dsvm*/*/logs/>
- ReadmeName /help/tempest-logs.html
+<% @readmes.each do |pattern| -%>
+ <%= pattern %>>
+ ReadmeName <%= @readmes[pattern] %>
+<% end -%>
/periodic*/*>
IndexOrderDefault Descending Date