On Fri, Aug 17, 2012 at 2:38 PM, Jeff Sussna <j...@ingineering.it> wrote:
> Hmm..it appears that $::path is returning multiple copies of the Puppet
> paths, along with "/user/bin" (which as you can imagine causes problems for
> Windows), in addition to the explicitly defined PATH string. Any idea why?
>

So I get:

C:\work\puppet> envpuppet puppet apply -e "notice($::path)"
notice: Scope(Class[main]):
c:\work\puppet\ext\..\bin;c:\work\puppet\ext\..\..\facter\bin;c:\puppetwinbuilder\sys\ruby\bin;c:\ruby187\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;c:\bin;c:\puppetwinbuilder\sys\git\bin;c:\puppetwinbuilder\sys\git\bin;C:\Chocolatey\bin;c:\work\puppet\ext;/usr/sbin;/sbin

The `:path` setting is populated from the environment, but we also add
in /usr/sbin and /sbin (in defaults.rb), obviously not helpful. Filed
as https://projects.puppetlabs.com/issues/16019. With that said it
shouldn't prevent the exec from working.

You can do something like the following to see how puppet resolves
which cmd.exe to run:

C:\work\puppet>envpuppet irb
irb(main):001:0> require 'puppet'
=> true
irb(main):002:0> Puppet::Util.which('cmd.exe')
=> "C:/Windows/system32/cmd.exe"

Or is it not finding reg.exe?

Josh

-- 
Josh Cooper
Developer, Puppet Labs

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

Reply via email to