Ask Your Question
0

Is it possible to update/ write new configuration in hiera_hash with facter or puppet code?

asked 2016-03-31 07:53:23 -0500

updated 2016-04-01 02:26:42 -0500

I would like to update and maintain my configurations in hiera_hash files. Already, The Hiera_Hash file holds some predefined values. Based on users input I would like to add/ update the new configurations in the hiera_hash file. To do that, I am trying to write it in Factor level and puppet code level. But No idea whether it will work or not.

Guys, Please let me know Whether my scenario is possible / not.

Any help would be much appreciated !!!

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
1

answered 2016-04-01 09:24:37 -0500

DarylW gravatar image

updated 2016-04-01 09:26:07 -0500

Relating to alex's comment, There currently exist lots of custom hiera backends.. . MySQL-hiera backends, dynamodb backends, consul backends, etc... Many different types of key-value stores that you can tie into.

consul

etcd - https://forge.puppetlabs.com/garethr/...

From the bottom of the 'backends' page that alex linked...

edit flag offensive delete link more

Comments

1

Hiera consul looks very cool. Thanks!

Alex Harvey gravatar imageAlex Harvey ( 2016-04-01 20:14:47 -0500 )edit
0

answered 2016-04-01 02:37:10 -0500

updated 2016-04-01 20:15:38 -0500

It's not clear what the problem is that you're trying to solve, although I can say there's definitely no way you can update the Hiera files from your Puppet manifest code. It's conceivable that a custom Hiera backend might help you. You could write a backend that is updated by user input, I suppose. I think, more likely, you're on the wrong track. Ask a different question explaining what the problem is you're trying to solve and I might be able to help further.

edit flag offensive delete link more

Your Answer

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

Add Answer

Question Tools

2 followers

Stats

Asked: 2016-03-31 07:53:23 -0500

Seen: 97 times

Last updated: Apr 01 '16