The unless parameter is only accepted by the exec resource. You're trying 
to use it in a package resource, and thus the error you're getting. You 
sort of need to make sure that the class that this resource is enclosed in 
is only include'd on those nodes that need it.

On Friday, March 1, 2013 12:00:24 PM UTC-8, Tiago Cruz wrote:
>
> Hello all!
>
> I would like to install one package, but only with some condition was ok, 
> like:
>
>  package { "nagios-plugins-basic":
>     ensure => "1.4.15-personal1",
>     unless => "test `ls -ld /opt/nrpe* 2>/dev/null | wc -l` -ge 1",
>   }
>
> but this not work =/
>
> Could not retrieve catalog from remote server: Error 400 on SERVER: 
> Invalid parameter unless at 
> /etc/puppet/modules/nagios/manifests/ubuntu.pp:13 on node 
> domu-12-31-39-0c-24-ce.compute-1.internal
>
> How can I do this?
>
> 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