Hi all,

if I define a file resource without specifying an ensure parameter, it 
seems to behave like ensure => present was specified.
I'm trying to require a file only when a command is executed, using 
something like this:

file{'myfile':
    path => '/tmp/myfile',
    source => "puppet:///modules/myexample/myfile",
    }

exec { "myexec":
    command => "/usr/local/bin/do_something -f /tmp/myfile",
    onlyif => "/usr/local/bin/mytest",
    require => [
               File["myfile"],
               ];
    }

but it always creates myfile, regardless to mytest.
Is there a way to bind the creation to the onlyif test?

Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-users@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to