Hello Bruce, Am 13.10.2010 19:36, schrieb Bruce Richardson: > On Wed, Oct 13, 2010 at 07:05:29PM +0200, Dennis Hoppe wrote: >> >> node "rumpel" inherits "default" { >> include apticron >> include ldap::slave >> include metche >> include puppet::master >> include rsyslog::master >> } >> >> node "samson" inherits "default" { >> include apticron >> include ldap::node >> include metche >> include puppet::node >> include rsyslog::node >> } >> >> If i run "puppetd --test --verbose" on host "rumpel" it is getting the >> "monit" configs for "puppetd" and "puppetmaster", which is intended to >> be. But the host "samson" is also getting the config for "puppetmaster", >> which is reproducible. > > This is almost certainly because of where you have included the monit > class, which is not visible in the modules you have attached here. I > could speculate about that, but I don't know how you've written the rest > of your manifests.
maybe you are right. If i use something like that, my problem seems to be solved. Because in this case i am making a node specific declaration, which i have to made for all my nodes and services. But i was looking for some kind of automatism, because the "monit" module should come with certain modules, which are choosing the right "monit" config. node "rumpel" inherits "default" { include apticron include ldap::slave include metche include monit monit::lenny::config { "puppet": } monit::lenny::config { "puppetmaster": } monit::lenny::config { "rsyslog": } monit::lenny::config { "ssh": } include puppet::master include rsyslog::master } > One thing, though: you have a huge amount of duplicated code there; it's > more work than you need to do and a potential source of error. Your > lenny and squeeze monit classes, for example, are almost identical; it > would make much more sense to have one class and use selectors ("if", > "case" etc.) for the minor bits which are different. As things stand, > if you change the structure of your monit module, you'll have to make > changes twice: once in the lenny version, once in the squeeze version. > You have so many duplicate classes that you're bound to slip somewhere > and make the change in one version and not in the other (or do it > slightly differently in the other). That kind of thing can be very > difficult to trace. Right, some other people at this mailing list already gave me that advice. I know that i have a lot of duplicated code, but i thought this would be easier to maintain, if a release is getting end of live status. Anyway, i am experiencing the first trouble with the way how i choose the releases and should think about a redesign of my puppet modules. Fortunately i am just at the beginning. ;) Regards, Dennis
signature.asc
Description: OpenPGP digital signature