mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-28 00:04:04 +02:00
puppet: Let icingaweb2::config::module() use the config path defined by hiera
This commit is contained in:
parent
513fbe6461
commit
bf68ecfa8c
@ -1,6 +1,25 @@
|
|||||||
define icingaweb2::config::module ($source, $module = 'monitoring', $replace = true) {
|
define icingaweb2::config::module (
|
||||||
icingaweb2::config::general { "modules/${module}/${name}":
|
$module,
|
||||||
source => $source,
|
$source,
|
||||||
|
$config = hiera('icingaweb2::config'),
|
||||||
|
$replace = true
|
||||||
|
) {
|
||||||
|
include icingaweb2::config
|
||||||
|
|
||||||
|
if ! defined(File["${config}/modules/${module}"]) {
|
||||||
|
file { "${config}/modules/${module}":
|
||||||
|
ensure => directory,
|
||||||
|
owner => 'root',
|
||||||
|
group => 'icingaweb',
|
||||||
|
mode => '2770',
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
file { "${config}/modules/${module}/${name}.ini":
|
||||||
|
source => "${source}/modules/${module}/${name}.ini",
|
||||||
|
owner => 'root',
|
||||||
|
group => 'icingaweb',
|
||||||
|
mode => 0660,
|
||||||
replace => $replace,
|
replace => $replace,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user