mirror of
https://github.com/actions/runner-images.git
synced 2025-12-20 06:35:47 +00:00
fix nuget installation win2016
This commit is contained in:
@@ -30,6 +30,9 @@ function Disable-UserAccessControl {
|
||||
Write-Host "User Access Control (UAC) has been disabled."
|
||||
}
|
||||
|
||||
# Set TLS1.2
|
||||
[Net.ServicePointManager]::SecurityProtocol = [Net.ServicePointManager]::SecurityProtocol -bor "Tls12"
|
||||
|
||||
Import-Module -Name ImageHelpers -Force
|
||||
|
||||
Write-Host "Setup PowerShellGet"
|
||||
@@ -98,7 +101,6 @@ else {
|
||||
}
|
||||
|
||||
# Run the installer
|
||||
[Net.ServicePointManager]::SecurityProtocol = [Net.ServicePointManager]::SecurityProtocol -bor "Tls12"
|
||||
Invoke-Expression ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))
|
||||
|
||||
# Turn off confirmation
|
||||
|
||||
Reference in New Issue
Block a user