You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -213,6 +224,10 @@ function Install-OSServerPreReqs
213
224
if (([version]$version).Major -eq8-and ([version]$version) -ge [version]$script:OSDotNetHostingBundleReq['8']['Version']) {
214
225
$installDotNetHostingBundle8=$false
215
226
}
227
+
# Check .NET 10.0
228
+
if (([version]$version).Major -eq10-and ([version]$version) -ge [version]$script:OSDotNetHostingBundleReq['10']['Version']) {
229
+
$installDotNetHostingBundle10=$false
230
+
}
216
231
}
217
232
218
233
if ($installDotNetHostingBundle6) {
@@ -221,7 +236,9 @@ function Install-OSServerPreReqs
221
236
if ($installDotNetHostingBundle8) {
222
237
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Stream 0-Message "Minimum .NET Windows Server Hosting version 8.0.0 for OutSystems $MajorVersion not found. We will try to download and install the latest .NET Windows Server Hosting bundle"
223
238
}
224
-
239
+
if ($installDotNetHostingBundle10) {
240
+
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Stream 0-Message "Minimum .NET Windows Server Hosting version 10.0.2 for OutSystems $MajorVersion not found. We will try to download and install the latest .NET Windows Server Hosting bundle"
241
+
}
225
242
226
243
# Check .NET version
227
244
if ($(GetDotNet4Version) -lt$script:OSDotNetReqForMajor[$MajorVersion]['Value'])
@@ -455,6 +472,63 @@ function Install-OSServerPreReqs
455
472
}
456
473
}
457
474
475
+
# Install .NET Windows Server Hosting bundle version 10
476
+
if ($installDotNetHostingBundle10)
477
+
{
478
+
try
479
+
{
480
+
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Stream 0-Message "Installing .NET 10.0 Windows Server Hosting bundle"
WriteNonTerminalError -Message ".NET 10.0 installer not found"
487
+
488
+
$installResult.Success=$false
489
+
$installResult.ExitCode=-1
490
+
$installResult.Message='.NET 10.0 installer not found'
491
+
492
+
return$installResult
493
+
}
494
+
catch
495
+
{
496
+
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Exception $_.Exception-Stream 3-Message "Error downloading or starting the .NET 10.0 installation"
497
+
WriteNonTerminalError -Message "Error downloading or starting the .NET 10.0 installation"
498
+
499
+
$installResult.Success=$false
500
+
$installResult.ExitCode=-1
501
+
$installResult.Message='Error downloading or starting the .NET 10.0 installation'
502
+
503
+
return$installResult
504
+
}
505
+
506
+
switch ($exitCode)
507
+
{
508
+
0
509
+
{
510
+
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Stream 0-Message ".NET 10.0 Windows Server Hosting bundle successfully installed."
511
+
}
512
+
513
+
{ $_-in3010,3011 }
514
+
{
515
+
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Stream 0-Message ".NET 10.0 Windows Server Hosting bundle successfully installed but a reboot is needed. Exit code: $exitCode"
516
+
$installResult.RebootNeeded=$true
517
+
}
518
+
519
+
default
520
+
{
521
+
LogMessage -Function $($MyInvocation.Mycommand) -Phase 1-Stream 3-Message "Error installing .NET 10.0 Windows Server Hosting bundle. Exit code: $exitCode"
522
+
WriteNonTerminalError -Message "Error installing .NET 10.0 Windows Server Hosting bundle. Exit code: $exitCode"
523
+
524
+
$installResult.Success=$false
525
+
$installResult.ExitCode=$exitCode
526
+
$installResult.Message='Error installing .NET 10.0 Windows Server Hosting bundle'
527
+
528
+
return$installResult
529
+
}
530
+
}
531
+
}
458
532
459
533
if ($mostRecentHostingBundleVersion-and$RemovePreviousHostingBundlePackages)
Copy file name to clipboardExpand all lines: src/Outsystems.SetupTools/Lib/Common.ps1
+29Lines changed: 29 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -367,3 +367,32 @@ function ValidateMinimumRequiredVersion()
367
367
368
368
return$true
369
369
}
370
+
371
+
# Checks if the ZoneId (not AppZoneId) is different than 0 (non local)
372
+
# ZoneId identifies the general security zone (e.g., Internet, Intranet) from which a file was downloaded, determining how strictly Windows treats the file.
373
+
# AppZoneId is a specialized, often temporary, identifier used by applications (like Microsoft SmartScreen) to manage trust exceptions after a user has decided to "Run" a file, often replacing or bypassing the original ZoneId to prevent future security prompts for that specific file
374
+
# It is possible to test this by modifying alternate data stream Set-Content -Path <file> -Stream Zone.Identifier -Value "[ZoneTransfer]`nZoneId=1"
LogMessage -Function $Function-Phase 1-Stream 1-Message "$($Path) might be blocked (ZoneId <> 0). Depending on the windows policies of the machine the installation might get stuck."
0 commit comments