Where you call the class you mention nodes_data, and inside the class it's node_data. Unless this is not a one-to-one copy-paste that might be your problem?
On Wed, Feb 22, 2012 at 15:21, M. Piscaer <deb...@masterpe.nl> wrote: > Hi, > > I have an problem that I can't get resolved. I have an hash like > www.krzywanski.net/archives/703. > > With this hash i whould like the add some extra hashes before passing to the > module, i have tryed the code below. > > > node testnode { > class { 'testclass': > nodes_data => { > 'node1' => { 'server' => 'node1.some.domain.com', 'port' => > '2560' }, > 'node2' => { 'server' => 'node2.another.domain.com', 'port' => > '2564' }, > 'node3' => { 'server' => 'node3.some.domain.com', 'port' => > '2564' } > } > } > } > > class testclass ( $node_data ) { > node_data += { > 'node4' => { 'server' => 'node4.another.domain.com', 'port' => '2564' > }, > 'node5' => { 'server' => 'node5.some.domain.com', 'port' => '2564' } > } > > class { 'moduletest::test': > module_variable => $node_data > } > } > > But then I get the error: > > err: Could not retrieve catalog from remote server: Error 400 on SERVER: > Cannot append, variable node_data is defined in this scope at > /opt/puppet/env/manifests/classes/testclass.pp:1 on node > testmp-test-04.intern > warning: Not using cache on failed catalog > err: Could not retrieve catalog; skipping run > > Without adding the information everything works fine. > > > Kind regards, > > Michiel Piscaer > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To post to this group, send email to puppet-users@googlegroups.com. > To unsubscribe from this group, send email to > puppet-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/puppet-users?hl=en. > -- Walter Heck -- follow @walterheck on twitter to see what I'm up to! -- Check out my new startup: Server Monitoring as a Service @ http://tribily.com Follow @tribily on Twitter and/or 'Like' our Facebook page at http://www.facebook.com/tribily -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.