Improve domain enrollment and desktop personalization
This commit is contained in:
@@ -622,13 +622,7 @@ $collectorFqdn = "$env:COMPUTERNAME.$DomainName"
|
||||
$userPolicyParameters = @{
|
||||
TargetOuDn = $usersOuDn
|
||||
DomainController = $env:COMPUTERNAME
|
||||
}
|
||||
$wallpaper = Get-ChildItem -LiteralPath $PackageSharePath -File -ErrorAction SilentlyContinue |
|
||||
Where-Object { $_.BaseName -eq 'wallpaper' -and $_.Extension -in @('.jpg','.jpeg','.png','.bmp') } |
|
||||
Sort-Object Name |
|
||||
Select-Object -First 1
|
||||
if ($wallpaper) {
|
||||
$userPolicyParameters.WallpaperPath = "\\$env:COMPUTERNAME\Packages\$($wallpaper.Name)"
|
||||
ClearManagedWallpaper = $true
|
||||
}
|
||||
& (Join-Path $scriptsRoot 'Set-SguDomainUserPolicies.ps1') @userPolicyParameters | Out-Null
|
||||
|
||||
|
||||
Reference in New Issue
Block a user