It would seem to me that I would not eagerly use another gem to obtain 
information from a file when ruby has File and vast string compare options 
but the choice is yours. Then there are tools like augeas (sp?).

Gems can be managed as a package using the gem provider so it's fairly easy 
to get puppet clients to install gems and note that facts run first so the 
first pass, the fact will not have information as the gem would likely have 
to be installed and the second pass, the fact can be derived.

On Friday, October 17, 2014 8:03:36 AM UTC-7, Mark Rosedale wrote:
>
> Hello,
>
> I'm looking to implement a custom fact that tells my puppet config if a 
> machine is configured a certain way. What I want to do is parse the 
> configuration's ini file and see if a certain setting is turned on or off. 
> I'm looking at using the ruby gem inifile 
> <https://rubygems.org/gems/inifile>to do this. 
>
> Couple of questions. I'm assuming that facts, unlike functions, are run on 
> the node, correct? So if that is the case what is the best way to 
> distribute this gem to all hosts? 
>
> Final question. Am I barking up the wrong tree trying to use this library 
> to parse an ini file? Has anyone else done this type of thing?  
>

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/f38be6ad-2d2f-40b9-a5e9-a3e9d94b2dc9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to