diff options
Diffstat (limited to 'manifests/ui.pp')
-rw-r--r-- | manifests/ui.pp | 37 |
1 files changed, 23 insertions, 14 deletions
diff --git a/manifests/ui.pp b/manifests/ui.pp index 0a12af0..dc51bfc 100644 --- a/manifests/ui.pp +++ b/manifests/ui.pp @@ -72,7 +72,7 @@ class tripleo::ui ( $servername = $::fqdn, $bind_host = undef, $ui_port = 3000, - $keystone_url = hiera('keystone::endpoint::public_url'), + $keystone_url = hiera('keystone_auth_uri_v2'), $heat_url = hiera('heat::keystone::auth::public_url', undef), $ironic_url = hiera('ironic::keystone::auth::public_url', undef), $mistral_url = hiera('mistral::keystone::auth::public_url', undef), @@ -82,19 +82,28 @@ class tripleo::ui ( ) { ::apache::vhost { 'tripleo-ui': - ensure => 'present', - servername => $servername, - ip => $bind_host, - port => $ui_port, - docroot => '/var/www/openstack-tripleo-ui/dist', - options => ['Indexes', 'FollowSymLinks'], - rewrites => [ - { - comment => 'Redirect 404 to index', - rewrite_cond => ['%{REQUEST_FILENAME} !-f', '%{REQUEST_FILENAME} !-d'], - rewrite_rule => ['(.*) index.html'], - }, - ], + ensure => 'present', + servername => $servername, + ip => $bind_host, + port => $ui_port, + docroot => '/var/www/openstack-tripleo-ui/dist', + options => ['Indexes', 'FollowSymLinks'], + fallbackresource => '/index.html', + } + + # We already use apache::vhost to generate our own + # configuration file, let's clean the configuration + # embedded within the package + file { "${apache::confd_dir}/openstack-tripleo-ui.conf" : + ensure => present, + content => "# +# This file has been cleaned by Puppet. +# +# OpenStack TripleO UI configuration has been moved to: +# - 25-tripleo-ui.conf +#", + require => Package['openstack-tripleo-ui'], + before => Service[$::apache::params::service_name], } file { '/var/www/openstack-tripleo-ui/dist/tripleo_ui_config.js' : |