Azure / azure-devtestlab

Azure DevTestLab artifacts, scripts and samples
MIT License
458 stars 602 forks source link

Minimum version check should be 5.0 not 3.0 #781

Open iamrawgavin opened 3 years ago

iamrawgavin commented 3 years ago

Line 73 Test-PowerShellVersion -Version 3.0

This check is for the PSWindowsUpdate module.

However, on line 76 there is this Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force | Out-Null

Line 76 requires Powershell 5 or higher. When I tried to add this artifact to an image with an older version of Windows (e.g. Server 2012 R2), the artifact fails.

iamrawgavin commented 3 years ago

RE: https://github.com/Azure/azure-devtestlab/blob/master/Artifacts/windows-install-windows-updates/artifact.ps1