Ask Your Question

How to distribute hiera files with puppet modules via puppet forge?

asked 2016-01-11 08:13:02 -0600

izza gravatar image

Hi all,

I'm using puppet 3.4.3, and my modules are tightly coupled to hiera. I would like to know the options that I have for distributing the hiera files (hiera.yaml and a few basic yaml backend files which users can customize to suit their needs) with puppet modules. The requirement is, when the user does puppet module install <module>, the hiera files should be copied to default data directory (/etc/puppet/hieradata). If there is a better way to do this, kindly let me know.


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2016-01-11 21:52:59 -0600

Unfortunately, a Puppet Forge module should not be tightly coupled to Hiera. Hiera is supposed to contain only site-specific data. A params class typically contains world-wide default settings. If you show me the code, I'd be happy to give you some advice on how to refactor.

edit flag offensive delete link more


Thanks Alex. Let me go through and try to understand the refactoring needed on y own first, and then I'll get your input to find the best way. Thanks again!

izza gravatar imageizza ( 2016-01-11 22:45:09 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2016-01-11 08:11:25 -0600

Seen: 8,066 times

Last updated: Jan 11 '16