fix: Use hiera auto data binding for base::packages::shells
This commit is contained in:
parent
93d03fa4bd
commit
1d12ccfc96
9
data/common.yaml
Normal file
9
data/common.yaml
Normal file
@ -0,0 +1,9 @@
|
||||
lookup_options:
|
||||
base::packages::shells:
|
||||
merge: unique
|
||||
|
||||
base::packages::shells::shells:
|
||||
- bash
|
||||
- zsh
|
||||
- ksh
|
||||
- fish
|
12
hiera.yaml
12
hiera.yaml
@ -5,11 +5,9 @@ defaults:
|
||||
# file (this file)
|
||||
# When specifying a datadir, make sure the directory exists.
|
||||
# See https://puppet.com/docs/puppet/latest/environments_about.html for further details on environments.
|
||||
# datadir: data
|
||||
# data_hash: yaml_data
|
||||
datadir: data
|
||||
data_hash: yaml_data
|
||||
|
||||
hierarchy:
|
||||
- name: "Per-node data (yaml version)"
|
||||
path: "nodes/%{::trusted.certname}.yaml"
|
||||
- name: "Other YAML hierarchy levels"
|
||||
paths:
|
||||
- "common.yaml"
|
||||
- name: "Global Base Configuration"
|
||||
paths: "common.yaml"
|
||||
|
@ -1,4 +1,5 @@
|
||||
class base inherits base::params {
|
||||
include base::users
|
||||
include base::dummy
|
||||
include base::packages
|
||||
}
|
||||
|
12
modules/base/manifests/packages.pp
Normal file
12
modules/base/manifests/packages.pp
Normal file
@ -0,0 +1,12 @@
|
||||
class base::packages {
|
||||
include base::packages::shells
|
||||
}
|
||||
|
||||
class base::packages::shells {
|
||||
$shells.each | String $value | {
|
||||
package { "${value}":
|
||||
ensure => installed,
|
||||
name => "${value}",
|
||||
}
|
||||
}
|
||||
}
|
@ -9,7 +9,7 @@ class security::firewall::nftables {
|
||||
name => 'nftables',
|
||||
}
|
||||
~> file { default: *=> $security::params::file_defaults;
|
||||
"/etc/nftables.conf":
|
||||
'/etc/nftables.conf':
|
||||
ensure => present,
|
||||
source => 'puppet:///modules/security/firewall/nftables/nftables.conf',
|
||||
;
|
||||
|
Loading…
x
Reference in New Issue
Block a user