Hi,
I'm updating an existing Puppet module so that I can use it with Hiera.
The node yaml files contains the following
selinux::mode: 'enforcing'
selinux::booleans:
'httpd_can_network_connect':
ensure: true
'httpd_setrlimit':
ensure: true
I can get the lookup to work using the following class:
class selinux (
$mode = $::selinux::params::mode,
### START Hiera Lookups ###
$selinux_booleans = {}
### END Hiera Lookups ###
) inherits selinux::params {
class { 'selinux::package': } ->
class { 'selinux::config': }
$booleans = hiera('selinux::booleans')
create_resources('selinux::boolean', $booleans)
}
But it doesn't work with the one below (which is the format I've seen used elsewhere):
class selinux (
$mode = $::selinux::params::mode,
### START Hiera Lookups ###
$selinux_booleans = {}
### END Hiera Lookups ###
) inherits selinux::params {
class { 'selinux::package': } ->
class { 'selinux::config': }
create_resources('selinux::boolean', $selinux_booleans)
}
Please could somebody let me know why the latter of the two doesn't work?
Thanks,
A