File tree 4 files changed +21
-1
lines changed
4 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -253,9 +253,21 @@ End If
253
253
<%- if @platform . architecture == "x86" -%>
254
254
< Property Id ="WixQuietExecCmdLine " Value =""[%WINDIR]\System32\WindowsPowerShell\v1.0\powershell.exe" -NoLogo -NonInteractive -InputFormat None -NoProfile -ExecutionPolicy Bypass -Command "if (Test-Path -Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components') { Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components' -Recurse | foreach { foreach ($prop in $_.Property) { if($_.GetValue($prop) -like '*service\nssm.exe*') { Set-ItemProperty -Path $_.PSPath -Name $prop -Value '' -ErrorAction Stop } } }; Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components' -Recurse | foreach { foreach ($prop in $_.Property) { if($_.GetValue($prop) -like '*puppet\bin\nssm.exe*') { Set-ItemProperty -Path $_.PSPath -Name $prop -Value '' -ErrorAction Stop } } } }" "/>
255
255
< CustomAction Id ="RemoveLegacyNssmRegistryKey " BinaryKey ="WixCA " DllEntry ="WixQuietExec " Execute ="immediate " Return ="check "/>
256
+ < Property Id ="WixSilentExecCmdLine " Value =""[%WINDIR]\System32\WindowsPowerShell\v1.0\powershell.exe" try {$check_long_path_enabled = Get-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" | Select-Object -ExpandProperty "LongPathsEnabled" -ErrorAction Stop;if($check_long_path_enabled -ne 1 ){throw "Value needs to be 1"}} catch { New-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" -Name "LongPathsEnabled" -Value 1 -PropertyType DWORD -Force } "/>
257
+ < CustomAction Id ="EnableLongPathName "
258
+ BinaryKey ="WixCA "
259
+ DllEntry ="WixSilentExec "
260
+ Execute ="immediate "
261
+ Impersonate ="yes " />
256
262
<%- else-%>
257
263
< Property Id ="WixQuietExec64CmdLine " Value =""[%WINDIR]\System32\WindowsPowerShell\v1.0\powershell.exe" -NoLogo -NonInteractive -InputFormat None -NoProfile -ExecutionPolicy Bypass -Command "if (Test-Path -Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components') { Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components' -Recurse | foreach { foreach ($prop in $_.Property) { if($_.GetValue($prop) -like '*service\nssm.exe*') { Set-ItemProperty -Path $_.PSPath -Name -Value '' $prop -ErrorAction Stop } } }; Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components' -Recurse | foreach { foreach ($prop in $_.Property) { if($_.GetValue($prop) -like '*puppet\bin\nssm.exe*') { Set-ItemProperty -Path $_.PSPath -Name $prop -Value '' -ErrorAction Stop } } } }" "/>
258
264
< CustomAction Id ="RemoveLegacyNssmRegistryKey " BinaryKey ="WixCA " DllEntry ="WixQuietExec64 " Execute ="immediate " Return ="check "/>
265
+ < Property Id ="WixSilentExec64CmdLine " Value =""[%WINDIR]\System32\WindowsPowerShell\v1.0\powershell.exe" try{$check_long_path_enabled = Get-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" | Select-Object -ExpandProperty "LongPathsEnabled" -ErrorAction Stop;if($check_long_path_enabled -ne 1 ){throw "Value needs to be 1"}} catch { New-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" -Name "LongPathsEnabled" -Value 1 -PropertyType DWORD -Force } "/>
266
+ < CustomAction Id ="EnableLongPathName "
267
+ BinaryKey ="WixCA "
268
+ DllEntry ="WixSilentExec64 "
269
+ Execute ="immediate "
270
+ Impersonate ="yes " />
259
271
<%- end -%>
260
272
261
273
<!-- Due to PUP-6729, system may not have permission to modify DACL, so first take ownership -->
Original file line number Diff line number Diff line change 50
50
Id ="WIXUI_EXITDIALOGOPTIONALTEXT "
51
51
Value ="Manage your first resources on this node, explore the Puppet community and get support using the shortcuts in the Documentation folder of your Start Menu. " />
52
52
53
+ < Property
54
+ Id ="WIXUI_EXITDIALOGOPTIONALCHECKBOXTEXT "
55
+ Value ="Disable Windows path length limit (260 character MAX_PATH limitation, requires Windows 10 1607 or later) " />
56
+
53
57
<!-- ***NOTE***
54
58
When originally moving to vanagon builds of puppet-agent (specifically for 1.6.0 and 1.6.1),
55
59
we wrote several registry entries to the wrong place. We fixed the issue in 1.6.2, but in order
Original file line number Diff line number Diff line change 150
150
< Custom Action ='SetFromIniPuppetServerPort ' Before ='FileCost '>
151
151
INI_PUPPET_SERVER_PORT AND NOT PUPPET_SERVER_PORT
152
152
</ Custom >
153
-
153
+ < Custom Action ='EnableLongPathName ' Before ='InstallFiles '>
154
+ ENABLE_LONG_PATHS
155
+ </ Custom >
154
156
<!-- Due to PUP-6729, make sure admins and system have permision to reset permissions -->
155
157
<!-- Also resets permissions for children beneath each appdir -->
156
158
< Custom Action ='ResetDataPermissions ' After ='InstallFiles '>
Original file line number Diff line number Diff line change @@ -59,6 +59,7 @@ Patch dialog sequence:
59
59
< Publish Dialog ="BrowseDlg " Control ="OK " Event ="SpawnDialog " Value ="InvalidDirDlg " Order ="4 "> <![CDATA[WIXUI_INSTALLDIR_VALID< > "1"]]> </ Publish >
60
60
61
61
< Publish Dialog ="ExitDialog " Control ="Finish " Event ="EndDialog " Value ="Return " Order ="999 "> 1</ Publish >
62
+ < Publish Dialog ="ExitDialog " Control ="Finish " Event ="DoAction " Value ="EnableLongPathName " Order ="999 "> WIXUI_EXITDIALOGOPTIONALCHECKBOX = 1</ Publish >
62
63
63
64
< Publish Dialog ="PuppetWelcomeDlg " Control ="Next " Event ="NewDialog " Value ="PuppetLicenseAgreementDlg " Order ="1 "> <![CDATA[NOT Installed]]> </ Publish >
64
65
< Publish Dialog ="PuppetWelcomeDlg " Control ="Next " Event ="NewDialog " Value ="VerifyReadyDlg " Order ="1 "> <![CDATA[Installed AND PATCH]]> </ Publish >
@@ -93,6 +94,7 @@ Patch dialog sequence:
93
94
< Publish Dialog ="BrowseDlg " Control ="OK " Event ="SpawnDialog " Value ="InvalidDirDlg " Order ="4 "> <![CDATA[WIXUI_INSTALLDIR_VALID< > "1"]]> </ Publish >
94
95
95
96
< Publish Dialog ="ExitDialog " Control ="Finish " Event ="EndDialog " Value ="Return " Order ="999 "> 1</ Publish >
97
+ < Publish Dialog ="ExitDialog " Control ="Finish " Event ="DoAction " Value ="EnableLongPathName " Order ="999 "> WIXUI_EXITDIALOGOPTIONALCHECKBOX = 1</ Publish >
96
98
97
99
< Publish Dialog ="PuppetWelcomeDlg " Control ="Next " Event ="NewDialog " Value ="PuppetLicenseAgreementDlg " Order ="1 "> <![CDATA[NOT VersionNT64 AND NOT Installed]]> </ Publish >
98
100
< Publish Dialog ="PuppetWelcomeDlg " Control ="Next " Event ="NewDialog " Value ="VerifyReadyDlg " Order ="1 "> <![CDATA[NOT VersionNT64 AND Installed AND PATCH]]> </ Publish >
You can’t perform that action at this time.
0 commit comments