On Sep 6, 2011, at 11:58 AM, Douglas Garstang wrote: > On Tue, Sep 6, 2011 at 11:52 AM, Douglas Garstang > <doug.garst...@gmail.com> wrote: >> The puppet documentation at >> http://docs.puppetlabs.com/references/stable/function.html says for >> the require function, that: >> >> "Evaluate one or more classes, adding the required class as a dependency." >> >> This implies that any resources in the required class are >> automatically added as a dependancy. I'm NOT seeing this behaviour. >> How is it supposed to work? >> >> Doug >> > > Actually, more specifically, I have this: > > class platform::common { > file { > '/etc/somedir': > ensure => directory; > } > > class webapp::common { > require "platform::common" > file { > "/etc/somedir/configfile": > # stuff here. > } > } > > When puppet runs, it's trying to apply the file > /etc/somedir/configfile _before_ /etc/somedir. This seems to > contradict the behaviour the documentation describes. ---- Suggest you try this... class webapp::common { include platform::common file { "/etc/somedir/configfile": require => Class["platform::common"], # stuff here. } }
Craig -- 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.