Hiera is able to read yaml files based on facts, .e.g. if facter domain returns dev.example.com and a dev.example.com.yaml file exist the file is read and the key-values are used. Using hiera can reduce the number of Puppet code lines.

learn more… | top users | synonyms

0
votes
1answer
12 views

Using hiera to include modules in example42/apache

I'm trying to set up a puppet configuration for work (open source version), and my goal is to create a sort of standard class that most of our servers could just use with a simple hiera_include in the ...
0
votes
1answer
31 views

Puppet: How to fix “Unknown function hiera_include”?

I've installed Puppet using the foreman-installer and it installed successfully. Then, I wanted to install Hiera as I have some modules which use hiera functions so I've installed hiera and created a ...
0
votes
1answer
55 views

Disable Puppet ENC part in Foreman

I looked for this for days now, and I'm quite depressed. We want to use Foreman as a monitoring and provisionnig tool. We would like to deactivate Foreman's ENC and use only Hiera. How could I manage ...
0
votes
0answers
46 views

How do dynamically get the hostname of another machine in hiera?

I have a few machines, one of those has the class dbserver assigned via ENC. The other machines run software which need the DB. Now I want to configure this software to be able to connect to the DB. I ...
1
vote
2answers
100 views

Optionally pass parameter to puppet using hiera

We're using the roles/profiles pattern. In the example below I'd like to optionally pass a parameter from hiera so that if no value is provided then the ::apache class default is used (which it gets ...
3
votes
1answer
192 views

Satellite 6's puppet is unable to find the hiera data sources

Using Satellite 6 which comes with Foreman 1.6.0.53. By default, Puppetlabs' documentation states that hiera configuration should be in $config/hiera.yaml. # puppet config print confdir hiera_config ...
1
vote
0answers
433 views

Puppet node no picking up hiera parameter from global.yaml file

I am using Foreman, Puppet and Hiera to provide parameter data for my nodes. Each node has its own node.yaml file on the Puppet Master in /etc/puppet/hieradata. There is also a global.yaml file ...
1
vote
2answers
242 views

Get value from hiera hash in Puppet

I have this structure in my hiera file that create some rules in my smb.conf. samba::shares: PDF: - comment = "PDF" - path = /home/smb/pdf - browseable = yes - hide dot files = yes ...
-3
votes
1answer
88 views

Puppet noob, stuck on the same error for hours

I'm trying to setup a puppet master with hiera. When I try "puppet agent --test" on the mongo node I get this error. Error: Could not retrieve catalog from remote server: Error 400 on SERVER: ...
0
votes
0answers
41 views

Securing SSL Keys (for production web application) with Puppet and Hiera

I'd like to know what is the best way to secure SSL keys and certificates for web applications. I am using the roles/profiles pattern. Here is the scenario: I have a web application. There is a ...
0
votes
1answer
163 views

Linux-Puppet: Error: Could not retrieve catalog from remote server, what could be the reason?

I've wrote a Puppet module which is supposed to create a directory, copy files into there and change the ownership of the files. The module name is "workspace". In the manifests folder of the module ...
1
vote
1answer
170 views

Puppet module not run on agents while this has been defined in Hiera on the Puppetmaster

Once I've installed Puppet, Foreman, Hiera and Facter, how do I get them all to work with one another? The Foreman GUI is operating properly and can be viewed using a browser. Hiera is installed, and ...
0
votes
1answer
803 views

How to return default hash keys in hiera_hash() call?

In an attempt to clean up my client's Hiera data for Puppet, and drastically reduce the number of Hiera calls in the Puppet manifests, I'm changing constructs like some_name::key1: a_value_1 ...
0
votes
1answer
157 views

How to instantiate multiple instances of the same resource using Hiera

Using Hiera, is it possible to instantiate two classes with different properties? I know I can do add to my node declaration: user{'francois': uid => 1000, # ... } user{'julien': uid => ...
3
votes
1answer
861 views

Trouble using hiera in masterless setup and getting values set for classes

I am running a masterless puppet setup that applies the puppet changes in the following manner. puppet apply /tmp/puppet/manifests/site.pp --modulepath=/tmp/puppet/modules ...
0
votes
1answer
187 views

Install of hiera-puppet-1.0.0-1.el6.noarch conflicts with file from package puppet-3.7.1-1.el6.noarch

Installing puppet and hiera sudo rpm -ivh http://yum.puppetlabs.com/el/6.4/products/x86_64/puppetlabs-release-6-11.noarch.rpm sudo yum update -y sudo yum -y install vim unzip rubygems puppet ...
1
vote
1answer
384 views

Using example of Hiera NTP in puppet does not work

I am currently trying to rebuild the example described here The Problem is, that when I try to get the ntp::servers variable I get the following error, which I have problems with understanding. ...
-1
votes
2answers
323 views

hiera.yaml is not loading on vagrant provision

Whenever I provision vagrant all the data is nil. When I ssh in and specify /etc/puppet/hiera.yaml as the config option i can get the values. How can I get vagrant to use the right hiera.config file? ...
1
vote
1answer
709 views

external fact not available at very first puppet run

Introduction: We are using puppet to configure the nodes via a custom fact which is then referenced in hiera. The fact can either reside in the golden image in /etc/facter/fact.d/ or via pluginsync ...
1
vote
0answers
273 views

need help writing puppet module for sssd.conf using Hiera

I need to build a module to manage /etc/sssd/sssd.conf on our Red Hat VMs. The sssd modules published on the forge don't seem to do what I want, nor do I feel like forking any of them. I want to keep ...
0
votes
2answers
122 views

Hiera datatypes wont load in Puppet

I have spent a couple of days on this, followed the instructions on http://downloads.puppetlabs.com/docs/puppetmanual.pdf and even the Puppet Training Advanced Puppet manual. When I run a test ...
0
votes
1answer
82 views

Puppet: Nagios with regex node names

I am configuring a puppet master and want to rely heavily on hiera. Many of my systems will be almost identical due to being scalable. I have therefore created node manifests which use regex rather ...
0
votes
1answer
58 views

Need help writing a wrapper for Hiera yaml data

This post seems like it might be helpful but I haven't been able to adapt it to my needs. The meat of it is: $custom_thing = ('custom_thing',{}) create_resources(param, $custom_thing) full post on ...
0
votes
1answer
400 views

Hiera concatenated lookup from yaml

I am trying to configure the puppet-logstash module via Hiera. When I make the call to hiera('profiles::logstash::config'), the return value is a concatenated string. It tells me that it cannot ...
1
vote
4answers
585 views

How do I use saz-sudo puppet module to deploy my own sudoers file with hiera?

I have saz-sudo installed and have created a site_sudo module based (I hope) on it. Here's what I have in my site_sudo/manifest/init.pp file: class { 'site_sudo': } sudo::conf { 'web': ...
6
votes
4answers
5k views

How to set up :datadir: when using Hiera with Puppet and Vagrant

I'd like to know how to set up :datadir: in hiera.yaml for optimal usage with Puppet and Vagrant. Currently I'm using vagrant 1.5.0 with virtualbox 4.2 on Ubuntu 13.10 with an Ubuntu 12.04 guest ...
0
votes
1answer
2k views

Puppet, hiera and erb - erb would not recognize array

I have a pretty annoying error I am desperate to fix. I have a puppet module where certain things are kept in a yaml file (hiera) so that people could quickly edit just that part. The structure is ...
2
votes
1answer
637 views

Different hiera hierarchy per dynamic environment

Is it possible to define a separate hiera.yaml for a given environment? Currently I am using dynamic environments. Each one has it's own hiera data directory, per my hiera.yaml file. :yaml: ...
3
votes
1answer
171 views

Puppet reporting without master

I am planning a Puppet infrastructure for about 100-200 servers. This is the design so far: Stash (git) for storing puppet config (not planning on using a master). Hiera to query either yaml, json, ...
3
votes
2answers
495 views

Manage enable - disable nginx site by Hiera puppet?

i got the task to implement hiera puppet script to manage sites_enabled for nginx. Here is my puppet script: common.yaml --- classes: - nginx nginx: enabled: abc.com ...
0
votes
1answer
967 views

Configuring puppetdb module in Puppet using Hiera

I'm trying to install the PuppetDB Module. Part of this bundles a module for installing some requisite Postgres instances which I am using as well. We primary use heira to configure roles and set ...
3
votes
4answers
2k views

hiera_include equivalent for resource types

I'm using the yumrepo built-in type. I can get a basic integration to hiera working yumrepo { hiera('yumrepo::name') : metadata_expire => hiera('yumrepo::metadata_expire'), descr ...
1
vote
1answer
289 views

converting node inheritance to hiera

I'm working on moving over a node inheritance tree to hiera. Presently working on the hierarchy. Prior to hiera, my nodes had a hierarchy as such base pre-prod qa nodes staging ...
1
vote
1answer
671 views

Hiera can't find puppet environment

I'm testing out hiera and hitting a snag on the hierarchy configuration. What I have is extremely simple, the part that isn't working is specification of hiera datadir files based on environment. ...
4
votes
1answer
436 views

hiera data source in using puppet syntax?

The documentation for hiera on docs.puppetlabs.com seems to give me the impression that I can use puppet syntax to describe my data. Or posssibly will be able to in the future. See: Coming soon. Is ...
3
votes
2answers
2k views

Hiera lookup based on pattern

I am trying to wrap my head around how I can transition from something I am doing in my large site.pp file into a structure I can use in hiera. It isn't clear to me from reading the puppet docs, ...
3
votes
1answer
731 views

Verifying hiera lookup for puppet

In the course of attempting to debug my puppet manifests numerous times after bundling it with hiera, sometimes I doubt whether the correct hiera lookup is even being performed. I am mostly using ...
3
votes
2answers
339 views

Pass same parameter value to multiple classes using Puppet Hiera

I'm using Hiera with Puppet and I want to pass the same parameter value to multiple classes without repeating it. Right now I've got (in Yaml): --- class_a::database_server: myoraclebox.example.com ...
1
vote
1answer
281 views

Handling exceptions for modules in Puppet

I have an LDAP module in Puppet that is used by 100 servers and edits about 10 files on all servers, before it runs authconfig --updateall to activate the new LDAP configuration. Most (98) of these ...
2
votes
0answers
463 views

Puppet/Hiera: Error 400 on SERVER: undefined method `empty_answer' for Hiera::Backend:Module

I had a puppet master running for quite some time. After a restart of the process recently, I started getting: # puppet agent -t info: Retrieving plugin info: Loading facts in ...
5
votes
2answers
4k views

Puppet&Hiera: $variable is not an hash or array when accessing it

I was using Puppet 3.2.2 and Hiera 1.2.1. And I wrote a puppet module and the content of init.pp was: class install( $common_instanceconfig = hiera_hash('common_instanceconfig'), ...
2
votes
2answers
2k views

How to exclude Puppet modules for a few nodes?

I have 80 nodes, 78 need to have a specific module, except for 2. [root@puppetmaster puppet]# cat hiera.yaml :backends: - yaml :hierarchy: - environment/%{::environment}/%{::hostname} - ...
0
votes
0answers
134 views

Using Hiera in Puppet, doesn't include Classes

My current folder structure looks like this: - manifests --hiera.yaml --site.pp --hieradata ---*.json --classes ---*.pp -modules --* Currently, hiera finds the configuration backends but doesn't ...
1
vote
1answer
663 views

How to use Hiera to assign modules to nodes in Puppet?

I have decided to switch from a single default nodes.pp to a Hiera back-end to manage nodes in Puppet and assign modules to nodes. We use hostnames as such: nyc-apache-prod-01 was-mysql-tst-01 ...
1
vote
1answer
819 views

puppet parameterized classes and hiera

I'm running puppet open source 3.1.0 from the puppetlabs repos on RedHat Enterprise Linux 6 and using hiera 1.1.2. I'm running into what seems like either a bug or a fundamental misunderstanding on my ...
1
vote
2answers
3k views

Using hiera to access facts of another node

What we're trying to do is generate firewall rules (puppetlabs/firewall) for iptables. Our nodes are grouped like so conceptually: -- site1 ---- shared1 ------ specific1 ------ specific2 ---- shared2 ...