Best way to parse yaml files inside puppet modules

Please tell, what best and generic way to parse foreman yaml in pupet
modules?

  1. With yalookup https://github.com/ohadlevy/puppet-lookup
  2. With hiera functions, like hiera, hiera_hash, hiera_array
  3. lookupvar

Or maybe other?

With regards, Vladislav.

I might suggest to create a puppet function that deserializes the yaml to
ruby objects and then provide some lookup methods that uses that object.

Corey

··· On Feb 13, 2013 11:27 AM, "Vlados Vlados" wrote:

Please tell, what best and generic way to parse foreman yaml in pupet
modules?

  1. With yalookup https://github.com/ohadlevy/puppet-lookup
  2. With hiera functions, like hiera, hiera_hash, hiera_array
  3. lookupvar

Or maybe other?

With regards, Vladislav.


You received this message because you are subscribed to the Google Groups
"Foreman users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to foreman-users+unsubscribe@googlegroups.com.
To post to this group, send email to foreman-users@googlegroups.com.
Visit this group at http://groups.google.com/group/foreman-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

> I might suggest to create a puppet function that deserializes the yaml to ruby objects and then provide some lookup methods that uses that object.
>
> Corey
>
> Please tell, what best and generic way to parse foreman yaml in pupet modules?
> 1) With yalookup https://github.com/ohadlevy/puppet-lookup
> 2) With hiera functions, like hiera, hiera_hash, hiera_array
> 3) lookupvar
>
> Or maybe other?
>

puppet-stdlib contains a paraseyaml function.

https://forge.puppetlabs.com/puppetlabs/stdlib

··· On Feb 13, 2013, at 6:31 PM, Corey Osman wrote: > On Feb 13, 2013 11:27 AM, "Vlados Vlados" wrote:

With regards, Vladislav.


You received this message because you are subscribed to the Google Groups “Foreman users” group.
To unsubscribe from this group and stop receiving emails from it, send an email to foreman-users+unsubscribe@googlegroups.com.
To post to this group, send email to foreman-users@googlegroups.com.
Visit this group at http://groups.google.com/group/foreman-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


You received this message because you are subscribed to the Google Groups “Foreman users” group.
To unsubscribe from this group and stop receiving emails from it, send an email to foreman-users+unsubscribe@googlegroups.com.
To post to this group, send email to foreman-users@googlegroups.com.
Visit this group at http://groups.google.com/group/foreman-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.