What is Hiera in puppet and what does it do?

0 votes
Why does puppet use Hiera. What exactly is that?
Jul 25, 2019 in Puppet by Karan
• 16,040 points
2,088 views

1 answer to this question.

0 votes

Hiera is probably a built-in key-value configuration data lookup system, used for separating data from Puppet code.

Puppet’s strength is in reusable code. Code that serves many needs must be configurable: put site-specific information in external configuration data files, rather than in the code itself.

Puppet uses Hiera to do two things:

  • Store the configuration data in key-value pairs
  • Look up what data a specific module needs for a given node during catalog compilation

This is done via:

  • Automatic Parameter Lookup for classes included within the catalog
  • Explicit lookup calls

Hiera’s hierarchical look ups follow a “defaults, with overrides” pattern, meaning you specify common data one time, and override it in situations where the default won’t work. 

Hiera uses Puppet’s facts to specify data sources, so you'll structure your overrides to fit your infrastructure. 

While using facts for this purpose is common, data-sources can also be defined without the use of facts.

Hiera supports JSON , YAML and EYAML files.

answered Jul 25, 2019 by Sirajul
• 57,890 points

Related Questions In Puppet

0 votes
1 answer

What does catalog do in puppet?

When a node is configured, puppet agent ...READ MORE

answered Jul 26, 2019 in Puppet by Sirajul
• 57,890 points
388 views
0 votes
1 answer

What is the use of etckeeper-commit-post and etckeeper-commit-pre on Puppet Agent?

Hey @Pallavi,  etckeeper-commit-post: In this configuration file you can ...READ MORE

answered Feb 15, 2019 in Puppet by Simran
272 views
0 votes
1 answer

What is class inheritance in Puppet?

What is class Inheritance? Node groups inherent properties ...READ MORE

answered Mar 5, 2019 in Puppet by Yogesh
243 views
0 votes
1 answer

What is resource declaration in Puppet?

Puppet code is composed primarily of resource declarations. ...READ MORE

answered Mar 11, 2019 in Puppet by Bob
54 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
675 views
+2 votes
1 answer
0 votes
1 answer

What is PSON in puppet and how is it different from JSON?

PSON is a variant of JSON which ...READ MORE

answered Jul 24, 2019 in Puppet by Sirajul
• 57,890 points
903 views
0 votes
1 answer