Unify Windows client bootstrap and discover network paths

This commit is contained in:
2026-09-10 08:13:46 -06:00
parent 74235ec6f8
commit 7f8a9eed4e
14 changed files with 634 additions and 219 deletions
+19 -31
View File
@@ -34,7 +34,7 @@ function Write-PackageManifest {
[Parameter(Mandatory)][string]$PackageRoot,
[Parameter(Mandatory)][string]$PackageVersion,
[Parameter(Mandatory)][string]$PackageKind,
[ValidateSet('Windows10Legacy', 'Windows11Modern')]
[ValidateSet('Auto')]
[string]$CompatibilityProfile,
[string]$TargetOperatingSystem
)
@@ -87,27 +87,24 @@ if (-not $runtimeInstaller) {
}
New-Item -ItemType Directory -Path $resolvedOutputRoot -Force | Out-Null
$windows11ClientRoot = Join-Path $resolvedOutputRoot "sgu-windows11-client-bootstrap-$Version"
$windows10ClientRoot = Join-Path $resolvedOutputRoot "sgu-windows10-legacy-client-bootstrap-$Version"
$clientRoot = $windows11ClientRoot
$clientRoot = Join-Path $resolvedOutputRoot "sgu-windows-client-bootstrap-$Version"
$serverRoot = Join-Path $resolvedOutputRoot "sgu-server-bootstrap-$Version"
$linuxClientRoot = Join-Path $resolvedOutputRoot "sgu-linux-client-bootstrap-$Version"
$azureRoot = Join-Path $resolvedOutputRoot "sgu-azure-infrastructure-$Version"
$windows11ClientZip = "$windows11ClientRoot.zip"
$windows10ClientZip = "$windows10ClientRoot.zip"
$clientZip = "$clientRoot.zip"
$serverZip = "$serverRoot.zip"
$linuxClientZip = "$linuxClientRoot.zip"
$azureZip = "$azureRoot.zip"
foreach ($target in @(
$windows11ClientRoot,$windows10ClientRoot,$serverRoot,$linuxClientRoot,$azureRoot,
$windows11ClientZip,$windows10ClientZip,$serverZip,$linuxClientZip,$azureZip)) {
$clientRoot,$serverRoot,$linuxClientRoot,$azureRoot,
$clientZip,$serverZip,$linuxClientZip,$azureZip)) {
if (Test-Path -LiteralPath $target) {
throw "Release target already exists: $target"
}
}
New-Item -ItemType Directory `
-Path $windows11ClientRoot,$windows10ClientRoot,$serverRoot,$linuxClientRoot,$azureRoot `
-Path $clientRoot,$serverRoot,$linuxClientRoot,$azureRoot `
-Force | Out-Null
$welcomeFontNames = @(
'IndivisaTextSans-Regular.otf',
@@ -154,25 +151,19 @@ foreach ($fontName in $welcomeFontNames) {
Copy-RequiredFile -Source $runtimeInstaller.FullName `
-Destination (Join-Path $clientRoot "payload\prerequisites\$($runtimeInstaller.Name)")
# Both Windows packages share the provider and enrollment implementation. The
# Windows 10 artifact freezes the direct-network compatibility surface, while
# the Windows 11 artifact adds the modern Azure P2S/pre-logon entry point.
Copy-Item -Path (Join-Path $windows11ClientRoot '*') `
-Destination $windows10ClientRoot -Recurse -Force
# One Windows implementation supports existing LAN/VPN routes and optional Azure P2S.
Copy-RequiredFile -Source (Join-Path $PSScriptRoot 'Start-SguAzureClientEnrollment.cmd') `
-Destination (Join-Path $windows11ClientRoot 'Start-SguAzureClientEnrollment.cmd')
-Destination (Join-Path $clientRoot 'Start-SguAzureClientEnrollment.cmd')
Copy-RequiredFile -Source (Join-Path $PSScriptRoot 'Install-SguAzureP2sClient.ps1') `
-Destination (Join-Path $windows11ClientRoot 'Install-SguAzureP2sClient.ps1')
-Destination (Join-Path $clientRoot 'Install-SguAzureP2sClient.ps1')
Copy-RequiredFile -Source (Join-Path $repositoryRoot 'docs\client-enrollment.md') `
-Destination (Join-Path $clientRoot 'README.md')
Copy-Item -Path (Join-Path $repositoryRoot 'docs\*.md') -Destination $clientRoot
Write-PackageManifest -PackageRoot $windows10ClientRoot -PackageVersion $Version `
-PackageKind WindowsClient -CompatibilityProfile Windows10Legacy `
-TargetOperatingSystem 'Windows 10 Pro, Enterprise, or Education (build below 22000)'
Write-PackageManifest -PackageRoot $windows11ClientRoot -PackageVersion $Version `
-PackageKind WindowsClient -CompatibilityProfile Windows11Modern `
-TargetOperatingSystem 'Windows 11 Pro, Enterprise, or Education (build 22000 or later)'
Compress-Archive -Path (Join-Path $windows10ClientRoot '*') -DestinationPath $windows10ClientZip `
-CompressionLevel Optimal
Compress-Archive -Path (Join-Path $windows11ClientRoot '*') -DestinationPath $windows11ClientZip `
Write-PackageManifest -PackageRoot $clientRoot -PackageVersion $Version `
-PackageKind WindowsClient -CompatibilityProfile Auto `
-TargetOperatingSystem 'Windows 10 1607+ or Windows 11; x64 Pro, Enterprise, or Education'
Compress-Archive -Path (Join-Path $clientRoot '*') -DestinationPath $clientZip `
-CompressionLevel Optimal
# Linux clients use their native PAM/SSSD sign-in stack rather than the Windows
@@ -272,8 +263,7 @@ Compress-Archive -Path (Join-Path $azureRoot '*') -DestinationPath $azureZip `
-CompressionLevel Optimal
$checksums = @(
("{0} {1}" -f (Get-FileHash -LiteralPath $windows10ClientZip -Algorithm SHA256).Hash, (Split-Path $windows10ClientZip -Leaf))
("{0} {1}" -f (Get-FileHash -LiteralPath $windows11ClientZip -Algorithm SHA256).Hash, (Split-Path $windows11ClientZip -Leaf))
("{0} {1}" -f (Get-FileHash -LiteralPath $clientZip -Algorithm SHA256).Hash, (Split-Path $clientZip -Leaf))
("{0} {1}" -f (Get-FileHash -LiteralPath $serverZip -Algorithm SHA256).Hash, (Split-Path $serverZip -Leaf))
("{0} {1}" -f (Get-FileHash -LiteralPath $linuxClientZip -Algorithm SHA256).Hash, (Split-Path $linuxClientZip -Leaf))
("{0} {1}" -f (Get-FileHash -LiteralPath $azureZip -Algorithm SHA256).Hash, (Split-Path $azureZip -Leaf))
@@ -283,10 +273,8 @@ $checksumsPath = Join-Path $resolvedOutputRoot "SHA256SUMS-$Version.txt"
[pscustomobject]@{
Version = $Version
Windows10LegacyClientPackage = $windows10ClientZip
Windows10LegacyClientSha256 = (Get-FileHash -LiteralPath $windows10ClientZip -Algorithm SHA256).Hash
Windows11ClientPackage = $windows11ClientZip
Windows11ClientSha256 = (Get-FileHash -LiteralPath $windows11ClientZip -Algorithm SHA256).Hash
WindowsClientPackage = $clientZip
WindowsClientSha256 = (Get-FileHash -LiteralPath $clientZip -Algorithm SHA256).Hash
LinuxClientPackage = $linuxClientZip
LinuxClientSha256 = (Get-FileHash -LiteralPath $linuxClientZip -Algorithm SHA256).Hash
ServerPackage = $serverZip