first application run?
How would you generally initialize them manually?
Asking to get better idea of the problem.
--
Krish
olindata.com
The right answer to these problems is almost always that you have a
`file { ".../foo": ensure => present }` resource in Puppet: that will
put it in place if the file is not present, using whatever source you
give, but will not touch the content of an existing file.
If you are using a recursive file resource to put the rest of the
content in place around this, no problem, because the more specific
file resource will override the recursive one, and you won't
overwrite. :)
--
Daniel Pittman
⎋ Puppet Labs Developer – http://puppetlabs.com
♲ Made with 100 percent post-consumer electrons
(I noted that; since this topic was followed up elsewhere I figured to
repeat myself. :)
> Ok Daniel, thanks for your reply, but I have not control about these
> individual "noreplace" files because are $hostname dependent.
Generally, what we would encourage is then that you define them on a
per-hostname basis. You can do that at the node level, or you can
push that down through a define or parameterized class, but the key is
to model that - on a per host basis.
I assume you meant "they are different on every host", rather than
literally being a file with the hostname in it; for that you could
just go with `file { "/path/to/${hostname}.cfg": ... }` to define the
files. :)
> hostname1/home/user/foo/bar/johndoe05/file1.cfg
> hostname2/home/user/foo/bar/maryjoe02/file1.cfg
>
> That was the reason for I need something recursive, similar to ignore
> parameter. (Or a workaround)
Define them per-node. :)
node hostname1 {
# define it in the node
include common::stuff
file { "/home/user/foo/bar/johndoe05/file1.cfg": ... }
# use a parameterized class
class { "something::else": configpath => "/home/user/foo/bar/johndoe05" }
# ...or a define.
some::define { "whatever": configpath => "/home/user/foo/bar/johndoe05" }