Refactor ssl_key to simplify horizon manifest
Change-Id: Id8098a6ee85224945408ec48a391c6f3937a4fd2
This commit is contained in:
parent
abc6204279
commit
a207b80f97
@ -27,26 +27,10 @@ class openstack_integration::horizon (
|
||||
include openstack_integration::params
|
||||
|
||||
if $::openstack_integration::config::ssl {
|
||||
file { '/etc/openstack-dashboard/ssl':
|
||||
ensure => directory,
|
||||
owner => 'root',
|
||||
mode => '0755',
|
||||
selinux_ignore_defaults => true,
|
||||
require => Package['horizon'],
|
||||
}
|
||||
file { '/etc/openstack-dashboard/ssl/private':
|
||||
ensure => directory,
|
||||
owner => 'root',
|
||||
mode => '0755',
|
||||
selinux_ignore_defaults => true,
|
||||
require => File['/etc/openstack-dashboard/ssl'],
|
||||
before => File["/etc/openstack-dashboard/ssl/private/${facts['networking']['fqdn']}.pem"],
|
||||
}
|
||||
openstack_integration::ssl_key { 'horizon':
|
||||
key_path => "/etc/openstack-dashboard/ssl/private/${facts['networking']['fqdn']}.pem",
|
||||
openstack_integration::ssl_key { 'openstack-dashboard':
|
||||
key_owner => 'root',
|
||||
require => File['/etc/openstack-dashboard/ssl/private'],
|
||||
notify => Service['httpd'],
|
||||
require => Anchor['horizon::install::end'],
|
||||
}
|
||||
Exec['update-ca-certificates'] ~> Service['httpd']
|
||||
}
|
||||
|
@ -26,13 +26,13 @@ define openstack_integration::ssl_key(
|
||||
if $key_path == undef {
|
||||
file { "/etc/${name}/ssl":
|
||||
ensure => directory,
|
||||
owner => $name,
|
||||
owner => $key_owner,
|
||||
mode => '0775',
|
||||
selinux_ignore_defaults => true,
|
||||
}
|
||||
file { "/etc/${name}/ssl/private":
|
||||
ensure => directory,
|
||||
owner => $name,
|
||||
owner => $key_owner,
|
||||
mode => '0755',
|
||||
require => File["/etc/${name}/ssl"],
|
||||
selinux_ignore_defaults => true,
|
||||
|
Loading…
Reference in New Issue
Block a user