Gmoney
2012-Mar-06 19:49 UTC
[Puppet Users] Applying specific file within list of files in a class
We push a number of standard files to deploy across all our servers, one of these files /etc/sysctl.conf , whihc is unique based on whether the server is a VM or a physical host. What is the best practice of pushing one unique file, which maintaining the push of the entire class of files? I am not aware of an exclusion within a class of files. would like to know how others are approaching this issues. I am running Puppet 2.9.11 on Red Hat 5.6. Thanks in advance for your advice. -- 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.
Dan White
2012-Mar-06 20:32 UTC
Re: [Puppet Users] Applying specific file within list of files in a class
http://docs.puppetlabs.com/references/stable/type.html#file source If you specify multiple file sources for a file, then the first source that exists will be used. This allows you to specify what amount to search paths for files: file { "/path/to/my/file": source => [ "/modules/nfs/files/file.$host", "/modules/nfs/files/file.$operatingsystem", "/modules/nfs/files/file" ] } This will use the first found file as the source. “Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us.” Bill Waterson (Calvin & Hobbes) ----- Gmoney <greg.caldwell7@gmail.com> wrote:> We push a number of standard files to deploy across all our servers, > one of these files /etc/sysctl.conf , whihc is unique based on whether > the server is a VM or a physical host. > > What is the best practice of pushing one unique file, which > maintaining the push of the entire class of files? > > I am not aware of an exclusion within a class of files. would like to > know how others are approaching this issues. I am running Puppet > 2.9.11 on Red Hat 5.6. Thanks in advance for your advice. > > -- > 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. >-- 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.