Kim Gert Nielsen wrote: > hmm then the debian version must be backported because it works in > 0.24.5-3 :) > > On Oct 15, 2009, at 1:36 PM, Marc Fournier wrote: > >> Beware that distributing facts and libs in modules doesn't work from >> environments before 0.25.
It may be more correct to say that per-environment facts don't work *reliably* before 0.25. The client would get its facts not from the environment it request its manifest from, but from the environment it used the *previous* time it connected to the Puppet-master. And for a new client, or after a restart of the master, they would get their facts from the default environment. So, this would happen: [Start puppetmasterd] # puppetd --environment=devel Gets facts from production, because that's what the default environment is # puppetd --environment=devel Now gets facts from devel, because that's what it asked for in the previous run # puppetd --environment=production Still gets facts from devel # puppetd --environment=devel Facts from production [Restart puppetmasterd] # puppetd --environment=devel Facts from production, because that's what the default environment is The problem before 0.25 was that the client only told the master about the wanted environment when it requested *manifests*, not when it downloaded files (using the puppet: URL scheme), so the master guessed what environment it used based on what it wanted the last time it asked for its manifests. And a typical run of puppetd would do this: 1. Download custom facts (and resource types) using the puppet: protocol (and thus without saying what environment it wanted) 2. Request compiled manifests for ENVIRONMENT. 3. Download files specified by the 'file' type using the puppet: protocol. which obviously fails. And note that while per-environment custom facts is supposed to work in 0.25 (I haven't tried it myself, though), you still cannot have custom resource types or custom functions per environment. /Bellman --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---