We have a command line utility that queries a database to get certain
facts about our hosts -- I wanted to write a custom function to obtain
all of those facts at once. The tool outputs JSON and I wanted to
take that output and return a hash back into puppet where I could
access the facts like...
$a = host_info()
if $a['in_maintenance'] == 'yes' {
} ...
etc, etc.
Right now I'm getting:
can't convert Array into String at ... Which I assume means that
puppet is expecting a string back from the custom function.
Maybe I just need to make a fact out of these instead and prefix them
with foo_in_maintenance, etc., etc., etc., but I'd really rather use
structured data.
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.