On Wed, Sep 07, 2011 at 02:25:21PM -0700, Douglas Garstang wrote: > On Wed, Sep 7, 2011 at 3:03 AM, R.I.Pienaar <r...@devco.net> wrote: > > > > > > ----- Original Message ----- > >> On Sep 6, 8:54 pm, "R.I.Pienaar" <r...@devco.net> wrote: > >> > ----- Original Message ----- > >> > > >> > files auto require their parents, it's not even needed to do > >> > the require => or require() > >> > > >> > > >> Could you please explain what exactly does it mean? Cheers!! > > > > Given 2 file resources: > > > > file{"/foo": ensure => directory} > > file{"/foo/bar": content => "hello world"} > > > > Actually, that's not true. I have seen numerous situations where > puppet tries to create /foo/bar before /foo, and then complains that > /foo does not exist. And, please don't get all pissy at me for having > a different view of this than you. > > Doug. >
I can only think of the situation that you manage File['/foo/bar'] but not have a File['/foo'] resource in your catalog. That means puppet does not automatically create parent directories (so no mkdir -p). It just establishes a relationship if you've also specified the parent directory as a puppet resource. There are different opinions if that is a good thing or a missing feature [1], personally I prefer the current explicit way. [1] http://projects.puppetlabs.com/issues/86 -Stefan
pgpq4gNzWXSfE.pgp
Description: PGP signature