Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/linker.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordotnet-maestro[bot] <42748379+dotnet-maestro[bot]@users.noreply.github.com>2020-08-31 15:46:11 +0300
committerGitHub <noreply@github.com>2020-08-31 15:46:11 +0300
commitd639a87084b316af931c34f3c45a3c746489902f (patch)
tree48d8e3ce3cf83ee614ca354d8b5a16448b5e15a0 /eng/common/tools.ps1
parentcefde0af8d4714c59b32eec1075f3e68a9666419 (diff)
Update dependencies from https://github.com/dotnet/arcade build 20200827.5 (#1463)
[master] Update dependencies from dotnet/arcade - Updates: - Microsoft.DotNet.Arcade.Sdk: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5 - Microsoft.DotNet.ApiCompat: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
Diffstat (limited to 'eng/common/tools.ps1')
-rw-r--r--eng/common/tools.ps120
1 files changed, 10 insertions, 10 deletions
diff --git a/eng/common/tools.ps1 b/eng/common/tools.ps1
index 6f8bc4111..c2e575c97 100644
--- a/eng/common/tools.ps1
+++ b/eng/common/tools.ps1
@@ -57,6 +57,11 @@ set-strictmode -version 2.0
$ErrorActionPreference = 'Stop'
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
+# If specifies, provides an alternate path for getting .NET Core SDKs and Runtimes. This script will still try public sources first.
+[string]$runtimeSourceFeed = if (Test-Path variable:runtimeSourceFeed) { $runtimeSourceFeed } else { $null }
+# Base-64 encoded SAS token that has permission to storage container described by $runtimeSourceFeed
+[string]$runtimeSourceFeedKey = if (Test-Path variable:runtimeSourceFeedKey) { $runtimeSourceFeedKey } else { $null }
+
function Create-Directory ([string[]] $path) {
New-Item -Path $path -Force -ItemType 'Directory' | Out-Null
}
@@ -223,7 +228,7 @@ function GetDotNetInstallScript([string] $dotnetRoot) {
}
function InstallDotNetSdk([string] $dotnetRoot, [string] $version, [string] $architecture = '') {
- InstallDotNet $dotnetRoot $version $architecture
+ InstallDotNet $dotnetRoot $version $architecture '' $false $runtimeSourceFeed $runtimeSourceFeedKey
}
function InstallDotNet([string] $dotnetRoot,
@@ -248,10 +253,8 @@ function InstallDotNet([string] $dotnetRoot,
& $installScript @installParameters
}
catch {
- Write-PipelineTelemetryError -Category 'InitializeToolset' -Message "Failed to install dotnet runtime '$runtime' from public location."
-
- # Only the runtime can be installed from a custom [private] location.
- if ($runtime -and ($runtimeSourceFeed -or $runtimeSourceFeedKey)) {
+ if ($runtimeSourceFeed -or $runtimeSourceFeedKey) {
+ Write-Host "Failed to install dotnet from public location. Trying from '$runtimeSourceFeed'"
if ($runtimeSourceFeed) { $installParameters.AzureFeed = $runtimeSourceFeed }
if ($runtimeSourceFeedKey) {
@@ -264,10 +267,11 @@ function InstallDotNet([string] $dotnetRoot,
& $installScript @installParameters
}
catch {
- Write-PipelineTelemetryError -Category 'InitializeToolset' -Message "Failed to install dotnet runtime '$runtime' from custom location '$runtimeSourceFeed'."
+ Write-PipelineTelemetryError -Category 'InitializeToolset' -Message "Failed to install dotnet from custom location '$runtimeSourceFeed'."
ExitWithExitCode 1
}
} else {
+ Write-PipelineTelemetryError -Category 'InitializeToolset' -Message "Failed to install dotnet from public location."
ExitWithExitCode 1
}
}
@@ -602,11 +606,7 @@ function MSBuild() {
if ($pipelinesLog) {
$buildTool = InitializeBuildTool
- # Work around issues with Azure Artifacts credential provider
- # https://github.com/dotnet/arcade/issues/3932
if ($ci -and $buildTool.Tool -eq 'dotnet') {
- dotnet nuget locals http-cache -c
-
$env:NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS = 20
$env:NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS = 20
Write-PipelineSetVariable -Name 'NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS' -Value '20'