Hi Gary,

On Wed, Apr 17, 2013 at 4:55 AM, Gary Park <gep...@gmail.com> wrote:

> Hello,
>
> Thanks for all the information so far.
>
> Looks like I have got this working.  I think that there was a couple
> things at play, most notable the use of double quotes in the onlyif command.
>
> I replaced these with \' and that seemed to help get things moving.
>

Since powershell variables are referenced using `$varname`, when they are
used in double-quoted strings, they need to be escaped, otherwise puppet
will think it's one of its variables. So you'll need to do:

    onlyif => "\$webRequest ..."

If you are not doing any variable interpolation, then it's best to use a
single quoted string:

    onlyif => '$webRequest ..."

Josh

-- 
Josh Cooper
Developer, Puppet Labs

*Join us at PuppetConf 2013, August 22-23 in San Francisco - *
http://bit.ly/pupconf13*
**Register now and take advantage of the Early Bird discount - save 25%!*

-- 
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