Merge "Avoid hard-coding OS user/group in each manifest"
This commit is contained in:
commit
8a6ff1a880
@ -25,7 +25,7 @@ class ironic::db::online_data_migrations(
|
||||
exec { 'ironic-db-online-data-migrations':
|
||||
command => "${::ironic::params::dbsync_command} ${extra_params} online_data_migrations ${migration_params}",
|
||||
path => '/usr/bin',
|
||||
user => 'ironic',
|
||||
user => $::ironic::params::user,
|
||||
refreshonly => true,
|
||||
try_sleep => 5,
|
||||
tries => 10,
|
||||
|
@ -25,8 +25,8 @@ class ironic::db::sync(
|
||||
# To be removed in Rocky.
|
||||
file { '/var/log/ironic/ironic-dbsync.log':
|
||||
ensure => 'present',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
# /var/log/ironic comes from ironic-common
|
||||
require => Anchor['ironic::install::end']
|
||||
}
|
||||
@ -34,7 +34,7 @@ class ironic::db::sync(
|
||||
exec { 'ironic-dbsync':
|
||||
command => "${::ironic::params::dbsync_command} ${extra_params}",
|
||||
path => '/usr/bin',
|
||||
user => 'ironic',
|
||||
user => $::ironic::params::user,
|
||||
refreshonly => true,
|
||||
try_sleep => 5,
|
||||
tries => 10,
|
||||
|
@ -249,8 +249,8 @@ class ironic::inspector (
|
||||
|
||||
file { '/etc/ironic-inspector/inspector.conf':
|
||||
ensure => 'present',
|
||||
owner => 'ironic-inspector',
|
||||
group => 'ironic-inspector',
|
||||
owner => $::ironic::params::inspector_user,
|
||||
group => $::ironic::params::inspector_group,
|
||||
require => Anchor['ironic-inspector::config::begin'],
|
||||
}
|
||||
|
||||
@ -266,8 +266,8 @@ class ironic::inspector (
|
||||
file { "${tftp_root_real}/pxelinux.cfg/default":
|
||||
ensure => 'present',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic-inspector',
|
||||
group => 'ironic-inspector',
|
||||
owner => $::ironic::params::inspector_user,
|
||||
group => $::ironic::params::inspector_group,
|
||||
content => template('ironic/inspector_pxelinux_cfg.erb'),
|
||||
require => Anchor['ironic-inspector::config::begin'],
|
||||
}
|
||||
@ -282,8 +282,8 @@ class ironic::inspector (
|
||||
file { "${http_root_real}/inspector.ipxe":
|
||||
ensure => 'present',
|
||||
seltype => 'httpd_sys_content_t',
|
||||
owner => 'ironic-inspector',
|
||||
group => 'ironic-inspector',
|
||||
owner => $::ironic::params::inspector_user,
|
||||
group => $::ironic::params::inspector_group,
|
||||
content => template('ironic/inspector_ipxe.erb'),
|
||||
require => Anchor['ironic-inspector::config::begin'],
|
||||
}
|
||||
@ -294,15 +294,15 @@ class ironic::inspector (
|
||||
file { "${tftp_root_real}/ppc64le":
|
||||
ensure => 'directory',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic-inspector',
|
||||
group => 'ironic-inspector',
|
||||
owner => $::ironic::params::inspector_user,
|
||||
group => $::ironic::params::inspector_group,
|
||||
require => Anchor['ironic-inspector::config::begin'],
|
||||
}
|
||||
file { "${tftp_root_real}/ppc64le/default":
|
||||
ensure => 'present',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic-inspector',
|
||||
group => 'ironic-inspector',
|
||||
owner => $::ironic::params::inspector_user,
|
||||
group => $::ironic::params::inspector_group,
|
||||
content => template('ironic/inspector_pxelinux_cfg.erb'),
|
||||
require => Anchor['ironic-inspector::config::begin'],
|
||||
}
|
||||
|
@ -17,7 +17,7 @@ class ironic::inspector::db::sync(
|
||||
exec { 'ironic-inspector-dbsync':
|
||||
command => $::ironic::params::inspector_dbsync_command,
|
||||
path => '/usr/bin',
|
||||
user => 'ironic-inspector',
|
||||
user => $::ironic::params::inspector_user,
|
||||
refreshonly => true,
|
||||
timeout => $db_sync_timeout,
|
||||
logoutput => on_failure,
|
||||
|
@ -29,7 +29,10 @@ class ironic::params {
|
||||
$client_package = 'python3-ironicclient'
|
||||
$inspector_client_package = 'python3-ironic-inspector-client'
|
||||
$lib_package_name = 'python3-ironic-lib'
|
||||
$user = 'ironic'
|
||||
$group = 'ironic'
|
||||
$inspector_user = 'ironic-inspector'
|
||||
$inspector_group = 'ironic-inspector'
|
||||
$sushy_package_name = 'python3-sushy'
|
||||
$proliantutils_package_name = 'python3-proliantutils'
|
||||
$dracclient_package_name = 'python3-dracclient'
|
||||
|
@ -106,8 +106,8 @@ class ironic::pxe (
|
||||
file { $tftp_root_real:
|
||||
ensure => 'directory',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
require => Anchor['ironic::config::begin'],
|
||||
before => Anchor['ironic::config::end'],
|
||||
}
|
||||
@ -121,8 +121,8 @@ class ironic::pxe (
|
||||
file { "${tftp_root_real}/pxelinux.cfg":
|
||||
ensure => 'directory',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
require => Anchor['ironic::install::end'],
|
||||
tag => 'ironic-tftp-file',
|
||||
}
|
||||
@ -130,8 +130,8 @@ class ironic::pxe (
|
||||
file { $http_root_real:
|
||||
ensure => 'directory',
|
||||
seltype => 'httpd_sys_content_t',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
require => Anchor['ironic::config::begin'],
|
||||
before => Anchor['ironic::config::end'],
|
||||
}
|
||||
@ -230,8 +230,8 @@ class ironic::pxe (
|
||||
file { "${tftp_root_real}/undionly.kpxe":
|
||||
ensure => 'file',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
mode => '0744',
|
||||
source => "${::ironic::params::ipxe_rom_dir}/undionly.kpxe",
|
||||
backup => false,
|
||||
@ -242,8 +242,8 @@ class ironic::pxe (
|
||||
file { "${tftp_root_real}/${uefi_ipxe_bootfile_name_real}":
|
||||
ensure => 'file',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
mode => '0744',
|
||||
source => "${::ironic::params::ipxe_rom_dir}/${ipxe_name_base}${arch}.efi",
|
||||
backup => false,
|
||||
|
@ -33,12 +33,13 @@ define ironic::pxe::tftpboot_file (
|
||||
$file = $title,
|
||||
) {
|
||||
include ironic::deps
|
||||
include ironic::params
|
||||
|
||||
file {"${destination_directory}/${file}":
|
||||
ensure => 'present',
|
||||
seltype => 'tftpdir_t',
|
||||
owner => 'ironic',
|
||||
group => 'ironic',
|
||||
owner => $::ironic::params::user,
|
||||
group => $::ironic::params::group,
|
||||
mode => '0744',
|
||||
source => "${source_directory}/${file}",
|
||||
backup => false,
|
||||
|
@ -139,7 +139,7 @@ class ironic::wsgi::apache (
|
||||
::openstacklib::wsgi::apache { 'ironic_wsgi':
|
||||
bind_host => $bind_host,
|
||||
bind_port => $port,
|
||||
group => 'ironic',
|
||||
group => $::ironic::params::group,
|
||||
path => $path,
|
||||
priority => $priority,
|
||||
servername => $servername,
|
||||
@ -152,7 +152,7 @@ class ironic::wsgi::apache (
|
||||
ssl_crl_path => $ssl_crl_path,
|
||||
ssl_key => $ssl_key,
|
||||
threads => $threads,
|
||||
user => 'ironic',
|
||||
user => $::ironic::params::user,
|
||||
vhost_custom_fragment => $vhost_custom_fragment,
|
||||
workers => $workers,
|
||||
wsgi_daemon_process => 'ironic',
|
||||
|
Loading…
x
Reference in New Issue
Block a user