Quantcast
Channel: Ask Puppet: Puppet DevOps Q&A Community - RSS feed
Viewing all articles
Browse latest Browse all 6104

how can i access fact hashes in hiera hierarchies

$
0
0
using puppet open source 3.8.4, hiera 1.3.4 and I am trying to figure out how to access a custom structured data fact to build out my hiera yaml hierarchy. when i run puppet in debug mode it doesn't find the component hierarchy, it just finds `environment/common` and `common`. As soon as i switch the fact from a hash to basic individual string variables and update the hierarchy to be `%{::component}` it finds the path. At what version did hiera support hashed facts in its config file, or am i missing something. **note** I have tried various different syntaxes of `::sapenvs:component` i.e; `::sapenvs[component]`, `::sapenvs.component`. **/etc/facter/facts.d/kickstart.yaml** --- sapenvs: component: 'ECC' **hiera.yaml** --- :backends: - yaml :yaml: :datadir: /opt/puppet/hieradata :hierarchy: - "%{::environment}/%{::sapenvs:component}/common" - "%{::environment}/common" - "common"

Viewing all articles
Browse latest Browse all 6104

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>