On Monday, June 29, 2015 at 4:01:36 PM UTC-5, Aaron Lager wrote:
>
> So I started over from scratch, and now I get the following error on the 
> agent:
>  sudo puppet agent --test
> Info: Retrieving pluginfacts
> Info: Retrieving plugin
> Info: Loading facts
> Error: Could not retrieve catalog from remote server: Error 400 on SERVER: 
> can't convert Array into Hash at 
> /etc/puppetlabs/puppet/environments/production/modules/hosts/manifests/init.pp:149
>  
> on node
>
> line 149 is
> 146   if $host_entries != undef {
> 147     $host_entries_real = delete($host_entries,$::fqdn)
> 148     validate_hash($host_entries_real)
> 149     create_resources(host,$host_entries_real)
> 150   }
>
>
> What is wrong with my syntax?
>
>

The module is using the create_resources() function, so the expected form 
for your data is exactly the one I guessed in my previous message: a hash 
in which the keys are host names (corresponding to Host resource names / 
titles), and the values are themselves hashes associating Host resource 
parameter names with values.  In addition to the example data, I provided 
links to the docs for the create_resources() function and the Host 
resource.  The error message seems to indicate that the data the module 
receives are formed differently than it expects, which would be true of 
both the forms you described using.


John

-- 
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 puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/7b181720-8e6e-4129-8a91-5969e01e5deb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to