Hi, I am attempting to follow the best practice guide as described here: http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice One question I have. Where should I place files for distribution that belong to stand alone classes? I.e. they are not part of a module? thanks, Iain. -- Iain Pople Systems Interface Technical Lead University of Melbourne --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Hi Iain, try /etc/puppet/manifests/classes/ that worked very well for me. Phillip Iain Pople schrieb:> Hi, > > I am attempting to follow the best practice guide as described here: > > http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice > > One question I have. Where should I place files for distribution that > belong to stand alone classes? I.e. they are not part of a module? > > thanks, Iain. > -- > Iain Pople > Systems Interface Technical Lead > University of Melbourne > > --~--~---------~--~----~------------~-------~--~----~ > 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 > -~----------~----~----~----~------~----~------~--~--- > >--
Isn''t that where the actual manifests go? What if I need to distribute a config file as part of a class? With the old best practice guide i would put it under /dist/ classname/, however the new best practice guide says to get rid of the /dist convention. On 01/07/2008, at 3:38 PM, Phillip Scholz wrote:> Hi Iain, > > try /etc/puppet/manifests/classes/ > that worked very well for me. > > Phillip > > > Iain Pople schrieb: >> Hi, >> I am attempting to follow the best practice guide as described here: >> http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice >> One question I have. Where should I place files for distribution >> that belong to stand alone classes? I.e. they are not part of a >> module? >> thanks, Iain. >> -- >> Iain Pople >> Systems Interface Technical Lead >> University of Melbourne >> > > -- >-- Iain Pople Systems Interface Technical Lead --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
I tend to have the following setup: /foo/bar/puppet /foo/bar/puppet/config /foo/bar/puppet/manifests then lets say i have a daemon class called ''daemon-mta-postfix'' i would have /foo/bar/puppet/manifets/daemons/mta-postfix.pp and then relevant config files would be as such /foo/bar/puppet/config/daemons/mta-postfix/main.cf Cheers Brendan Iain Pople wrote:> Isn''t that where the actual manifests go? What if I need to distribute > a config file as part of a class? > > With the old best practice guide i would put it under /dist/ > classname/, however the new best practice guide says to get rid of > the /dist convention. > > On 01/07/2008, at 3:38 PM, Phillip Scholz wrote: > > >> Hi Iain, >> >> try /etc/puppet/manifests/classes/ >> that worked very well for me. >> >> Phillip >> >> >> Iain Pople schrieb: >> >>> Hi, >>> I am attempting to follow the best practice guide as described here: >>> http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice >>> One question I have. Where should I place files for distribution >>> that belong to stand alone classes? I.e. they are not part of a >>> module? >>> thanks, Iain. >>> -- >>> Iain Pople >>> Systems Interface Technical Lead >>> University of Melbourne >>> >> -- >> >> > > -- > Iain Pople > Systems Interface Technical Lead > > > >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
I distribute config files via fileserv.conf and templating this would make them go to /etc/puppet/files/ and /etc/puppet/templates/ my fileserver.conf looks like this: [files] path /etc/puppet/files allow *.domain.tld [facts] path /etc/puppet/facts allow *.domain.tld [plugins] path /etc/puppet/plugins allow *.domain.tld [templates] path /etc/puppet/templates allow *.domain.tld Iain Pople schrieb:> Isn''t that where the actual manifests go? What if I need to distribute > a config file as part of a class? > > With the old best practice guide i would put it under /dist/ > classname/, however the new best practice guide says to get rid of > the /dist convention. > > On 01/07/2008, at 3:38 PM, Phillip Scholz wrote: > >> Hi Iain, >> >> try /etc/puppet/manifests/classes/ >> that worked very well for me. >> >> Phillip >> >> >> Iain Pople schrieb: >>> Hi, >>> I am attempting to follow the best practice guide as described here: >>> http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice >>> One question I have. Where should I place files for distribution >>> that belong to stand alone classes? I.e. they are not part of a >>> module? >>> thanks, Iain. >>> -- >>> Iain Pople >>> Systems Interface Technical Lead >>> University of Melbourne >> -- >> > > -- > Iain Pople > Systems Interface Technical Lead > > --~--~---------~--~----~------------~-------~--~----~ > 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 > -~----------~----~----~----~------~----~------~--~--- > >--
Iain Pople wrote:> I am attempting to follow the best practice guide as described here: > > http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice > > One question I have. Where should I place files for distribution that > belong to stand alone classes? I.e. they are not part of a module?I think one of the goals of their migration from the 1.0 to 2.0 was that they put practically every class into module form. One advantage of this would be in keeping all files associated with a particular class in one subdirectory of the module directories: much easier to bundle up and distribute that way. And I guess it would help if you needed to segment your version control as far as allowing group X to develop the platform-neutral Apache modules, but group Y to develop the baseline Solaris support, for example. With my manifests being about 80% pre-BestPractices, 5% BestPractices1.0, and 15% regular modules, I''ve got a considerable conversion effort ahead of me. But I''m starting to recognize that bundling everything up in modules has significant advantages. -- Mike Renfro / R&D Engineer, Center for Manufacturing Research, 931 372-3601 / Tennessee Technological University -- renfro@tntech.edu --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
On Tue, Jul 1, 2008 at 12:35 AM, Iain Pople <ipople@unimelb.edu.au> wrote:> > Hi, > > I am attempting to follow the best practice guide as described here: > > http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice > > One question I have. Where should I place files for distribution that > belong to stand alone classes? I.e. they are not part of a module? >Really the best for them would be puppet/files/ or /puppet/files/class/, if the class is at puppet/manifest/. I have found that if you start needing config files then it really is best practice to make it a module. I thin one of the things reflected in the Best Practice revision is that unless it really did go to every machine and really generic, that the best place for it was a module. The only thing I will be keeping in the main manifest now is node descriptions, a few general purpose utility definitions that are needed by all my modules, and site.pp. Evan --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Iain Pople <ipople@unimelb.edu.au> writes:> I am attempting to follow the best practice guide as described here: > > http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice > > One question I have. Where should I place files for distribution that > belong to stand alone classes? I.e. they are not part of a module?I would argue that there should be no such thing. Everything should be in a module, including classes for individual machines (which would get a module for that machine). That''s the model we''re following. -- Russ Allbery (rra@stanford.edu) <http://www.eyrie.org/~eagle/> --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
--On Tuesday, July 01, 2008 03:35:38 PM +1000 Iain Pople <ipople@unimelb.edu.au> wrote:> Hi, > > I am attempting to follow the best practice guide as described here: > > http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice > > One question I have. Where should I place files for distribution that > belong to stand alone classes? I.e. they are not part of a module?That''s a good question. Under the new best practice, it is rare to have standalone classes (I''m curious as to your exact scenario). But if needed, /dist would still be the place, I''d say. But you might see if those classes would''nt better fit in a module. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Ok, so the consensus seem to be that I shouldn''t be using stand alone classes. Fair enough. In that case how do I include one module in another? On 02/07/2008, at 11:11 AM, Digant C Kasundra wrote:> > --On Tuesday, July 01, 2008 03:35:38 PM +1000 Iain Pople > <ipople@unimelb.edu.au> wrote: > >> Hi, >> >> I am attempting to follow the best practice guide as described here: >> >> http://reductivelabs.com/trac/puppet/wiki/PuppetBestPractice >> >> One question I have. Where should I place files for distribution that >> belong to stand alone classes? I.e. they are not part of a module? > > That''s a good question. Under the new best practice, it is rare to > have > standalone classes (I''m curious as to your exact scenario). But if > needed, > /dist would still be the place, I''d say. But you might see if those > classes would''nt better fit in a module. > > > > >-- Iain Pople Systems Interface Technical Lead University of Melbourne --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Iain Pople wrote:> Ok, so the consensus seem to be that I shouldn''t be using stand alone > classes. Fair enough. > > In that case how do I include one module in another?As far as I can tell, modules just collect up everything into one folder tree. Classes, definitions, etc. are defined as normal, and are included or just used as normal once the module is imported in the site.pp. So you don''t include the module per se, you include the classes it defines. Example: David''s apt module at http://git.black.co.at/?p=module-apt;a=blob;f=manifests/init.pp uses a config_file definition from http://git.black.co.at/?p=module-common;a=blob;f=manifests/defines/config_file.pp Since config_file wasn''t inside a particular class, it''s in the top-level namespace. I assume he''s got an "import common" and an "import apt" in his site.pp somewhere that exposes the common definitions to his other manifests. I''ve got another example at http://blogs.cae.tntech.edu/mwr/2007/08/02/the-new-file-server-puppet-and-modules/ for an Amanda module. So the site.pp has an "import amanda", and for the host manifest that needed Amanda available, I just did an ''include amanda'' to get the class and all it contained. -- Mike Renfro / R&D Engineer, Center for Manufacturing Research, 931 372-3601 / Tennessee Technological University -- renfro@tntech.edu --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Iain Pople <ipople@unimelb.edu.au> writes:> Ok, so the consensus seem to be that I shouldn''t be using stand alone > classes. Fair enough. > > In that case how do I include one module in another?I assume that you''re asking how to include a class supplied by one module in a class supplied by another? In that case, include, just like you''d include a class in any other circumstance. If you meant something else, could you rephrase? -- Russ Allbery (rra@stanford.edu) <http://www.eyrie.org/~eagle/> --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---