Is there a way to look up which nodes share that specific module or class? # manifests/nodes.pp node 'serverA', 'serverB' { include puppet-tomcat::tomcatA }
I need to access variables from both servers. E.g. # worker.properties.erb <% for server in have_class_included('tomcatA') -%> JkWorkerProperty worker.<%= name %>.host=<%= server::ipaddress_eth0 %> <% end -%> which should result in two lines. One with the IP address of serverA and the other line with the IP address of serverB Currently I'm defining custom variables for each server: # manifests/nodes.pp if $fqdn == "serverA" { $ipA = 'localhost' $ipB = '222.222.222.222' } if $fqdn == "serverB" { $ipB = 'localhost' $ipA = '111.111.111.111' } and just hard code each worker # worker.properties.erb JkWorkerProperty worker.<%= name %>.host=<%= ipA %> JkWorkerProperty worker.<%= name %>.host=<%= ipB %> Which is just wrong, I know. Maybe there is another even simpler way to do it. Best regards, Andreas Paul -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/95YGM2IgT9gJ. 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.