Still on my sensor management project ;) I have a parameterised define (sensor) within a class monitor: class monitor { import "masters/*.pp" # class for each sensor master define sensor( $master, .....) # and I want to include a class whose name is give by $master. include $master #(with or without quotes) gives syntax errors. # alternatively just importing the specific manifest (rather than all in the import above): import "master/$master.pp" # also gives syntax error. } What I a trying to do is define some variables that will be used in erb templates which are specific to each master sensor. So I want to have a class for each master sensor which gets included in the sensor definition. Again I want these to be stand alone entities that can be in a file of their own and be automatically generated. Am I going about this the wrong way (again ;) ? Russell -- 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+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
russell.fulton
2010-Nov-22 02:57 UTC
[Puppet Users] Re: more than one instance of a service
I have worked my way around this one: empirical evidence suggest that one can use variable in include but not import. This makes some sort of sense. So I now import "master/*.pp" include $master This leads to another problem but I''ll post it to a thread of its own... Russell -- 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+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.