It appears that in version 0.23 of puppet that how I am trying to create directories is nor working. If I have a snippet like this: # Set up the images file {"$git_web_image_location": ensure => directory, recurse => true } which becomes: file {"/var/www/html/images/git": ensure => directory, recurse => true } I will get a failure if /var/www/html/images/ does not exist. Is this the correct way to try and create a structure? -- bk
--On Friday, September 21, 2007 9:07 AM -0400 Bryan Kearney <bkearney@redhat.com> wrote:> file {"/var/www/html/images/git": > ensure => directory, > recurse => true > } > > I will get a failure if /var/www/html/images/ does not exist. Is this > the correct way to try and create a structure? > > -- bkPuppet won''t create the upper directories. You currently have to specify each level and ensure they exists.
On 9/22/07, Digant C Kasundra <digant@stanford.edu> wrote:> > --On Friday, September 21, 2007 9:07 AM -0400 Bryan Kearney > <bkearney@redhat.com> wrote: > > > file {"/var/www/html/images/git": > > ensure => directory, > > recurse => true > > } > > > > I will get a failure if /var/www/html/images/ does not exist. Is this > > the correct way to try and create a structure? > > > > -- bk > > Puppet won''t create the upper directories. You currently have to specify > each level and ensure they exists.Or you can also use an exec syntax: exec { "create-git-web-image": command => "mkdir -p $git_web_image_location" } _______________________________________________> Puppet-users mailing list > Puppet-users@madstop.com > https://mail.madstop.com/mailman/listinfo/puppet-users >_______________________________________________ Puppet-users mailing list Puppet-users@madstop.com https://mail.madstop.com/mailman/listinfo/puppet-users
Is this by design? Seems like the resurse directive would do this. --- bk Digant C Kasundra wrote:> --On Friday, September 21, 2007 9:07 AM -0400 Bryan Kearney > <bkearney@redhat.com> wrote: > > >> file {"/var/www/html/images/git": >> ensure => directory, >> recurse => true >> } >> >> I will get a failure if /var/www/html/images/ does not exist. Is this >> the correct way to try and create a structure? >> >> -- bk >> > > Puppet won''t create the upper directories. You currently have to specify > each level and ensure they exists. > > > _______________________________________________ > Puppet-users mailing list > Puppet-users@madstop.com > https://mail.madstop.com/mailman/listinfo/puppet-users > >
On Sep 24, 2007, at 7:13 AM, Bryan Kearney wrote:> Is this by design? Seems like the resurse directive would do this.The recurse parameter causes downward recursion, and it would be a bit difficult to make it also go upward. That being said, for a long time it was essentially impossible. Now it''s just pretty difficult, and I haven''t had the time to fix it, especially considering how easy the workaround is. -- The death rate on Earth is: .... (computing) .... One per person. --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com