Issue #18295 has been updated by Josh Cooper.

Status changed from Unreviewed to Needs More Information

Hi Nathan, Can you run puppet apply with --debug and --trace and report the 
error you are seeing? I intentionally don't quote the command and 
{install|uninstall}_options as it was causing windows to think the options were 
part of the executable to run. For example, when uninstalling git, we have to 
execute the following:

<pre>
cmd.exe /c start puppet-uninstall /w "C:\Program Files (x86)\Git\unins000.exe" 
/SILENT
</pre>

If we instead did:

<pre>
cmd.exe /c start puppet-uninstall /w "C:\Program Files (x86)\Git\unins000.exe 
/SILENT"
</pre>

Then windows would try to execute a process named "C:\Program Files 
(x86)\Git\unins000.exe /SILENT" and fail.
----------------------------------------
Bug #18295: Windows Package installer_options not quoted when when source 
contains spaces
https://projects.puppetlabs.com/issues/18295#change-79862

Author: Nathan Buuck
Status: Needs More Information
Priority: Normal
Assignee: 
Category: windows
Target version: 
Affected Puppet version: 3.0.2
Keywords: windows package 
Branch: 


**Synopsis**:

When the puppet agent's "windows:" provider generates the Windows shell command 
to execute a self-extracting executable installer, the "installer_options" like 
"/s" are left outside of the double-quotes that enclose the "source". This 
causes the package's installer_options to be appended as if they're switches 
for the "start" process, which almost always causes the installation to fail.

**Example**:

    package { "Mozilla Firefox 17.0.1:
    ensure => installed,
    source => '\\NAS\Software\Mozilla\Firefox 17.0.1.exe',
    installer_options => [ '/s' ]
    }

The agent will attempt to execute a command similar to this (from memory, I'm 
afraid; the cmd.exe and start arguments may be swapped):
    cmd.exe /c start /w "\\NAS\Software\Mozilla\Firefox 17.0.1.exe" /s

Where as it should attempt to execute:
    cmd.exe /c start /w "\\NAS\Software\Mozilla\Firefox 17.0.1.exe /s"

**Other Notes**:

1. The issue occurs regardless of specifying the provider attribute of the 
package.
2. The agent was running on Windows 7 Professional x64.
3. The agent was Puppet Open Source 3.0.2 for Windows, installed silently via 
.MSI from http://puppetlabs.com/misc/download-options/


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en.

Reply via email to