Hi

> file { "/home/jeff/src/my/dir/path":
>   path    => "/home/jeff/src/my/dir/path",
>   mode    => 0755,
>   owner   => jeff,
>   group   => jeff,
>   ensure  => directory,
>   recurse => true,
> }
> 
> But puppet complains the parent directory doesn't exist. How can I do
> the equivalent of
> 
> mkdir -p /home/jeff/src/my/dir/path

with the file resource only with:

file { [ '/home/jeff/src/', '/home/jeff/src/my/',
'/home/jeff/src/my/dir', "/home/jeff/src/my/dir/path" :
[...]
}

this is due to various reasons. the main reason for that is imho as
puppet has to now about the things its manages. so to which point it
should go back? and what then?

recurse is only true from the managing point on deeper into the
filesystem. (usefull for purging or source synching)

another thing would be:

exec{'mkdir -p /home/jeff/src/my/dir/path':
        unless => 'test -d /home/jeff/src/my/dir/path',
}

which is indeed ugly, but quick.

greets pete

--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to