Hi, Recently I installed PE 2017.2 and got everything setup except hiera. Though I have used Hiera 3 it's going very tough to understand the configuration for all layers. However I have created a hiera.yaml in testing environment and defined the data structure like environment/data/node/mynode.yaml. Below is the content of hiera.yaml
---
version: 5
defaults: # Used for any hierarchy level that omits these keys.
datadir: data # This path is relative to hiera.yaml's directory.
data_hash: yaml_data # Use the built-in YAML backend.
hierarchy:
- name: "Per-node data"
path: "nodes/%{trusted.certname}.yaml"
Directory structure as follows:
[root@mobf7l4z0k testing]# ls data/nodes/
qde1ar.yaml
[root@mobf7l4z0k testing]# ls
data environment.conf hieradata manifests modules
[root@mobf7l4z0k testing]#
There's just one key in my qde1ar.yaml but I am not able to look that up. Getting following error:
> [root@mobf7l4z0k hieradata]# puppet> lookup name Warning:> /etc/puppetlabs/puppet/hiera.yaml: Use> of 'hiera.yaml' version 3 is> deprecated. It should be converted to> version 5 (in> /etc/puppetlabs/puppet/hiera.yaml)
Any idea how to fix it? Even I am not sure how to restrict my lookup to environment layer and it should not go and search for globally declared hiera structure.
↧