Daniel Pittman wrote:
amrset <[email protected]> writes:
Would it be possible to do something like:
file { "/foo/voo/bar/baz" :
ensure => directory,
between => {
start => "/foo",
end => "/foo/voo/bar",
owner => "foo",
group => "foo",
mode => 755, }
between => {
start => "/foo/voo/bar/baz",
end => "/foo/voo/bar/baz",
owner => "baz",
group => "baz",
mode => 775, }
}
Isn't that just:
file { "/foo": owner => "foo", recurse => true }
file { "/foo/voo/bar/baz": owner => "baz", recurse => true }
...since the second instance is more specific, so will override the first
instance?
Daniel
A few issues - first - which one would run first? (order would matter
right?)
Second - right now, if a parent directory doesn't exist, ie - if "bar"
below doesn't exist:
file { "/foo/voo/bar/baz" :
ensure => directory.
...
}
then the file resource throws an error that it can't create "baz" as it
currently can't deal with missing parent directories.
Another issue - what if $mydir is multiple (dynamic) levels of
directory, and I need to create and/or maintain /foo/${mydir}/bar/baz
... What if some of the tree exists on one computer and none on
another? What will the permissions/ownership be?
Regards,
-Roy
--
You received this message because you are subscribed to the Google Groups "Puppet
Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-dev?hl=en.