Wali/1634821 adopting private dotnet binaries (#1644)

* dotnet7 private rc2 changes

* adopting private binaries

* adopting private binaries changes

* private binaries changes

* private binaries changes

* private binaires changes

* pr changes

* pr changes

* env variable fix

* temporary fix

* private binaries changes

* dotnet 7 private sdk binaries

* check for null token

* allow sas token to be used to pull default version

Co-authored-by: Paul Dorsch <pauldorsch@microsoft.com>
This commit is contained in:
waliMSFT 2022-11-01 20:55:30 -04:00 коммит произвёл GitHub
Родитель 725a99cd94
Коммит b5830e08a1
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
23 изменённых файлов: 82 добавлений и 42 удалений

Просмотреть файл

@ -5,6 +5,7 @@ SDK_STORAGE_BASE_URL_KEY_NAME='ORYX_SDK_STORAGE_BASE_URL'
TESTING_SDK_STORAGE_URL_KEY_NAME='ORYX_TEST_SDK_STORAGE_URL'
DEV_SDK_STORAGE_BASE_URL='https://oryxsdksdev.blob.core.windows.net'
SANDBOX_SDK_STORAGE_BASE_URL='https://oryxsdkssandbox.blob.core.windows.net'
PRIVATE_SDK_STORAGE_BASE_URL='https://oryxsdksprivate.blob.core.windows.net'
PROD_SDK_STORAGE_BASE_URL='https://oryxsdksprod.blob.core.windows.net'
PROD_BACKUP_SDK_STORAGE_BASE_URL='https://oryxsdksprodbackup.blob.core.windows.net'
PROD_SDK_CDN_STORAGE_BASE_URL='https://oryx-cdn.microsoft.io'
@ -12,7 +13,7 @@ DEFAULT_VERSION_FILE_NAME='defaultVersion.txt'
DEFAULT_VERSION_FILE_PREFIX='defaultVersion'
DEFAULT_VERSION_FILE_TYPE='txt'
VERSIONS_TO_BUILD_FILE_NAME='versionsToBuild.txt'
CONTAINER_METADATA_URL_FORMAT='{0}/{1}?restype=container&comp=list&include=metadata&marker={2}'
CONTAINER_METADATA_URL_FORMAT='{0}/{1}?restype=container&comp=list&include=metadata&marker={2}&{3}'
SDK_DOWNLOAD_SENTINEL_FILE_NAME='.oryx-sdkdownload-sentinel'
SDK_VERSION_METADATA_NAME='Sdk_version'
LEGACY_SDK_VERSION_METADATA_NAME='Version'

Просмотреть файл

@ -324,6 +324,7 @@
testing-sdk-storage-url-key-name: ORYX_TEST_SDK_STORAGE_URL
dev-sdk-storage-base-url: https://oryxsdksdev.blob.core.windows.net
sandbox-sdk-storage-base-url: https://oryxsdkssandbox.blob.core.windows.net
private-sdk-storage-base-url: https://oryxsdksprivate.blob.core.windows.net
prod-sdk-storage-base-url: https://oryxsdksprod.blob.core.windows.net
prod-backup-sdk-storage-base-url: https://oryxsdksprodbackup.blob.core.windows.net
prod-sdk-cdn-storage-base-url: https://oryx-cdn.microsoft.io
@ -331,7 +332,7 @@
default-version-file-prefix: defaultVersion
default-version-file-type: txt
versions-to-build-file-name: versionsToBuild.txt
container-metadata-url-format: '{0}/{1}?restype=container&comp=list&include=metadata&marker={2}'
container-metadata-url-format: '{0}/{1}?restype=container&comp=list&include=metadata&marker={2}&{3}'
sdk-download-sentinel-file-name: .oryx-sdkdownload-sentinel
sdk-version-metadata-name: Sdk_version
legacy-sdk-version-metadata-name: Version

Просмотреть файл

@ -39,6 +39,7 @@
- 7.0.100-preview.7.22377.5
- 7.0.100-rc.1.22431.12
- 7.0.100-rc.2.22477.23
- 7.0.100-rc.2.22477.23
### buster
@ -95,6 +96,7 @@
- 7.0.100-preview.7.22377.5
- 7.0.100-rc.1.22431.12
- 7.0.100-rc.2.22477.23
- 7.0.100-rc.2.22477.23
### focal-scm
@ -151,6 +153,7 @@
- 7.0.100-preview.7.22377.5
- 7.0.100-rc.1.22431.12
- 7.0.100-rc.2.22477.23
- 7.0.100-rc.2.22477.23
### stretch

Просмотреть файл

@ -5,6 +5,7 @@ SDK_STORAGE_BASE_URL_KEY_NAME='ORYX_SDK_STORAGE_BASE_URL'
TESTING_SDK_STORAGE_URL_KEY_NAME='ORYX_TEST_SDK_STORAGE_URL'
DEV_SDK_STORAGE_BASE_URL='https://oryxsdksdev.blob.core.windows.net'
SANDBOX_SDK_STORAGE_BASE_URL='https://oryxsdkssandbox.blob.core.windows.net'
PRIVATE_SDK_STORAGE_BASE_URL='https://oryxsdksprivate.blob.core.windows.net'
PROD_SDK_STORAGE_BASE_URL='https://oryxsdksprod.blob.core.windows.net'
PROD_BACKUP_SDK_STORAGE_BASE_URL='https://oryxsdksprodbackup.blob.core.windows.net'
PROD_SDK_CDN_STORAGE_BASE_URL='https://oryx-cdn.microsoft.io'
@ -12,7 +13,7 @@ DEFAULT_VERSION_FILE_NAME='defaultVersion.txt'
DEFAULT_VERSION_FILE_PREFIX='defaultVersion'
DEFAULT_VERSION_FILE_TYPE='txt'
VERSIONS_TO_BUILD_FILE_NAME='versionsToBuild.txt'
CONTAINER_METADATA_URL_FORMAT='{0}/{1}?restype=container&comp=list&include=metadata&marker={2}'
CONTAINER_METADATA_URL_FORMAT='{0}/{1}?restype=container&comp=list&include=metadata&marker={2}&{3}'
SDK_DOWNLOAD_SENTINEL_FILE_NAME='.oryx-sdkdownload-sentinel'
SDK_VERSION_METADATA_NAME='Sdk_version'
LEGACY_SDK_VERSION_METADATA_NAME='Version'

Просмотреть файл

@ -4,7 +4,7 @@
# Licensed under the MIT license.
# --------------------------------------------------------------------------------------------
set -ex
set -e
declare -r REPO_DIR=$( cd $( dirname "$0" ) && cd .. && cd .. && pwd )
@ -47,7 +47,11 @@ getDotNetCoreSdk() {
if [ -z "$downloadUrl" ]; then
# Use default download url file
downloadUrl="https://dotnetcli.blob.core.windows.net/dotnet/Sdk/$sdkVersion/dotnet-sdk-$sdkVersion-linux-x64.tar.gz"
elif [[ "$downloadUrl" == *"dotnet-private"* ]]; then
# SAS-token is passed as en env-variable on the Oryx-PlatformBinary-DotNetCore pipeline
downloadUrl+=$DOTNET_PRIVATE_STORAGE_ACCOUNT_ACCESS_TOKEN
fi
tempDir="/tmp/oryx-dotnetInstall"
mkdir -p $tempDir

Просмотреть файл

@ -34,4 +34,7 @@
7.0.100-preview.6.22352.1, e49a2119021e4069f1193898536cc59628336e656f2f7e49d454a593a330d8e437acf2f4efb70925bc16a9c900c2e49f4a6c2fb5f69e696b09a91ebccd2c9307,
7.0.100-preview.7.22377.5, c16d452dbe4f097b75d304c8bc19892017847768bf2e8a0a72fafd6d6b46c3dd77e0c251b80c245197f47fdeafc2c18db255af8a1a5c30be982de19129874390
7.0.100-rc.1.22431.12, 7ecebf284bd1546e1575b9561f4e64bbb8d69680a7bbda6f06ff6fbf687d3a6c653b0e6a6c569241455c6f83620f0ddbe193ca5cd52384ac062c8565dd22b859,
7.0.100-rc.2.22477.23, 22db5d1d16f6fcedfc46f87896920425b5d9b61d09c47d254d6ac731c6d853657882b21faf21f313ed20b33e6331d01b9f723b2c586f0e0cf5acc5ed570b0260,
7.0.100-rc.2.22477.23, 22db5d1d16f6fcedfc46f87896920425b5d9b61d09c47d254d6ac731c6d853657882b21faf21f313ed20b33e6331d01b9f723b2c586f0e0cf5acc5ed570b0260,
7.0.100, 0a2e74486357a3ee16abb551ecd828836f90d8744d6e2b6b83556395c872090d9e5166f92a8d050331333d07d112c4b27e87100ba1af86cac8a37f1aee953078, https://dotnetcli.blob.core.windows.net/dotnet-private/Internal/7.0.0/dotnet-sdk-7.0.100-linux-x64.tar.gz,
# NOTE: Make sure to set the default version in 'defaultVersion.txt' file

Просмотреть файл

@ -52,4 +52,8 @@
7.0.100-preview.6.22352.1, e49a2119021e4069f1193898536cc59628336e656f2f7e49d454a593a330d8e437acf2f4efb70925bc16a9c900c2e49f4a6c2fb5f69e696b09a91ebccd2c9307,
7.0.100-preview.7.22377.5, c16d452dbe4f097b75d304c8bc19892017847768bf2e8a0a72fafd6d6b46c3dd77e0c251b80c245197f47fdeafc2c18db255af8a1a5c30be982de19129874390,
7.0.100-rc.1.22431.12, 7ecebf284bd1546e1575b9561f4e64bbb8d69680a7bbda6f06ff6fbf687d3a6c653b0e6a6c569241455c6f83620f0ddbe193ca5cd52384ac062c8565dd22b859,
7.0.100-rc.2.22477.23, 22db5d1d16f6fcedfc46f87896920425b5d9b61d09c47d254d6ac731c6d853657882b21faf21f313ed20b33e6331d01b9f723b2c586f0e0cf5acc5ed570b0260,
7.0.100-rc.2.22477.23, 22db5d1d16f6fcedfc46f87896920425b5d9b61d09c47d254d6ac731c6d853657882b21faf21f313ed20b33e6331d01b9f723b2c586f0e0cf5acc5ed570b0260,
7.0.100, 0a2e74486357a3ee16abb551ecd828836f90d8744d6e2b6b83556395c872090d9e5166f92a8d050331333d07d112c4b27e87100ba1af86cac8a37f1aee953078, https://dotnetcli.blob.core.windows.net/dotnet-private/Internal/7.0.0/dotnet-sdk-7.0.100-linux-x64.tar.gz,
# NOTE: Make sure to set the default version in 'defaultVersion.txt' file

Просмотреть файл

@ -52,4 +52,9 @@
7.0.100-preview.6.22352.1, e49a2119021e4069f1193898536cc59628336e656f2f7e49d454a593a330d8e437acf2f4efb70925bc16a9c900c2e49f4a6c2fb5f69e696b09a91ebccd2c9307,
7.0.100-preview.7.22377.5, c16d452dbe4f097b75d304c8bc19892017847768bf2e8a0a72fafd6d6b46c3dd77e0c251b80c245197f47fdeafc2c18db255af8a1a5c30be982de19129874390,
7.0.100-rc.1.22431.12, 7ecebf284bd1546e1575b9561f4e64bbb8d69680a7bbda6f06ff6fbf687d3a6c653b0e6a6c569241455c6f83620f0ddbe193ca5cd52384ac062c8565dd22b859,
7.0.100-rc.2.22477.23, 22db5d1d16f6fcedfc46f87896920425b5d9b61d09c47d254d6ac731c6d853657882b21faf21f313ed20b33e6331d01b9f723b2c586f0e0cf5acc5ed570b0260,
7.0.100-rc.2.22477.23, 22db5d1d16f6fcedfc46f87896920425b5d9b61d09c47d254d6ac731c6d853657882b21faf21f313ed20b33e6331d01b9f723b2c586f0e0cf5acc5ed570b0260,
7.0.100, 0a2e74486357a3ee16abb551ecd828836f90d8744d6e2b6b83556395c872090d9e5166f92a8d050331333d07d112c4b27e87100ba1af86cac8a37f1aee953078, https://dotnetcli.blob.core.windows.net/dotnet-private/Internal/7.0.0/dotnet-sdk-7.0.100-linux-x64.tar.gz,
# NOTE: Make sure to set the default version in 'defaultVersion.txt' file

Просмотреть файл

@ -9,6 +9,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator.Common
public const string TestingSdkStorageUrlKeyName = "ORYX_TEST_SDK_STORAGE_URL";
public const string DevSdkStorageBaseUrl = "https://oryxsdksdev.blob.core.windows.net";
public const string SandboxSdkStorageBaseUrl = "https://oryxsdkssandbox.blob.core.windows.net";
public const string PrivateSdkStorageBaseUrl = "https://oryxsdksprivate.blob.core.windows.net";
public const string ProdSdkStorageBaseUrl = "https://oryxsdksprod.blob.core.windows.net";
public const string ProdBackupSdkStorageBaseUrl = "https://oryxsdksprodbackup.blob.core.windows.net";
public const string ProdSdkCdnStorageBaseUrl = "https://oryx-cdn.microsoft.io";
@ -16,7 +17,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator.Common
public const string DefaultVersionFilePrefix = "defaultVersion";
public const string DefaultVersionFileType = "txt";
public const string VersionsToBuildFileName = "versionsToBuild.txt";
public const string ContainerMetadataUrlFormat = "{0}/{1}?restype=container&comp=list&include=metadata&marker={2}";
public const string ContainerMetadataUrlFormat = "{0}/{1}?restype=container&comp=list&include=metadata&marker={2}&{3}";
public const string SdkDownloadSentinelFileName = ".oryx-sdkdownload-sentinel";
public const string SdkVersionMetadataName = "Sdk_version";
public const string LegacySdkVersionMetadataName = "Version";

Просмотреть файл

@ -57,7 +57,8 @@ namespace Microsoft.Oryx.BuildScriptGenerator.DotNetCore
{
var httpClient = this.HttpClientFactory.CreateClient("general");
var sdkStorageBaseUrl = this.GetPlatformBinariesStorageBaseUrl();
var xdoc = ListBlobsHelper.GetAllBlobs(sdkStorageBaseUrl, DotNetCoreConstants.PlatformName, httpClient);
var oryxSdkStorageAccountAccessToken = this.commonOptions.OryxSdkStorageAccountAccessToken;
var xdoc = ListBlobsHelper.GetAllBlobs(sdkStorageBaseUrl, DotNetCoreConstants.PlatformName, httpClient, oryxSdkStorageAccountAccessToken);
// keys represent runtime version, values represent sdk version
var supportedVersions = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase);

Просмотреть файл

@ -5,15 +5,16 @@
using System.Linq;
using System.Xml.Linq;
using Microsoft.Oryx.BuildScriptGenerator.Common;
using Microsoft.Oryx.BuildScriptGenerator.DotNetCore;
namespace Microsoft.Oryx.BuildScriptGenerator
{
internal static class ListBlobsHelper
{
public static XDocument GetAllBlobs(string sdkStorageBaseUrl, string platform, System.Net.Http.HttpClient httpClient)
public static XDocument GetAllBlobs(string sdkStorageBaseUrl, string platform, System.Net.Http.HttpClient httpClient, string oryxSdkStorageAccountAccessToken)
{
var url = string.Format(SdkStorageConstants.ContainerMetadataUrlFormat, sdkStorageBaseUrl, platform, string.Empty);
var oryxSdkStorageAccountAccessArgs = oryxSdkStorageAccountAccessToken?.TrimStart(new char[] { '?' }) ?? string.Empty;
var url = string.Format(SdkStorageConstants.ContainerMetadataUrlFormat, sdkStorageBaseUrl, platform, string.Empty, oryxSdkStorageAccountAccessArgs);
var blobList = httpClient
.GetStringAsync(url)
.Result;
@ -24,7 +25,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator
// and consolidate blobs from all the pages.
do
{
url = string.Format(SdkStorageConstants.ContainerMetadataUrlFormat, sdkStorageBaseUrl, platform, marker);
url = string.Format(SdkStorageConstants.ContainerMetadataUrlFormat, sdkStorageBaseUrl, platform, marker, oryxSdkStorageAccountAccessArgs);
var blobListFromNextMarker = httpClient.GetStringAsync(url).Result;
var xdocFromNextMarker = XDocument.Parse(blobListFromNextMarker);
marker = xdocFromNextMarker.Root.Element("NextMarker").Value;

Просмотреть файл

@ -65,6 +65,8 @@ namespace Microsoft.Oryx.BuildScriptGenerator
public string OryxSdkStorageBaseUrl { get; set; }
public string OryxSdkStorageAccountAccessToken { get; set; }
public bool EnableTelemetry { get; set; }
public string PreBuildScriptPath { get; set; }

Просмотреть файл

@ -85,6 +85,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator
string directoryToInstall = null)
{
var sdkStorageBaseUrl = this.GetPlatformBinariesStorageBaseUrl();
var sdkStorageAccountAccessToken = this.CommonOptions.OryxSdkStorageAccountAccessToken;
var versionDirInTemp = directoryToInstall;
if (string.IsNullOrEmpty(versionDirInTemp))
@ -117,7 +118,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator
$"--output {tarFile} >/dev/null 2>&1")
.AppendLine("else")
.AppendLine(
$"curl -D headers.txt -SL \"{sdkStorageBaseUrl}/{platformName}/{platformName}-$DEBIAN_FLAVOR-{version}.tar.gz\" " +
$"curl -D headers.txt -SL \"{sdkStorageBaseUrl}/{platformName}/{platformName}-$DEBIAN_FLAVOR-{version}.tar.gz$ORYX_SDK_STORAGE_ACCOUNT_ACCESS_TOKEN\" " +
$"--output {tarFile} >/dev/null 2>&1")
.AppendLine("fi")
.AppendLine("PLATFORM_BINARY_DOWNLOAD_ELAPSED_TIME=$(($SECONDS - $PLATFORM_BINARY_DOWNLOAD_START))")

Просмотреть файл

@ -8,7 +8,6 @@ using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Net.Http;
using System.Xml.Linq;
using System.Xml.XPath;
using Microsoft.Extensions.Logging;
using Microsoft.Extensions.Options;
@ -51,7 +50,8 @@ namespace Microsoft.Oryx.BuildScriptGenerator
this.logger.LogDebug("Getting list of available versions for platform {platformName}.", platformName);
var httpClient = this.HttpClientFactory.CreateClient("general");
var sdkStorageBaseUrl = this.GetPlatformBinariesStorageBaseUrl();
var xdoc = ListBlobsHelper.GetAllBlobs(sdkStorageBaseUrl, platformName, httpClient);
var oryxSdkStorageAccountAccessToken = this.commonOptions.OryxSdkStorageAccountAccessToken;
var xdoc = ListBlobsHelper.GetAllBlobs(sdkStorageBaseUrl, platformName, httpClient, oryxSdkStorageAccountAccessToken);
var supportedVersions = new List<string>();
var isStretch = string.Equals(this.commonOptions.DebianFlavor, OsTypes.DebianStretch, StringComparison.OrdinalIgnoreCase);
@ -98,7 +98,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator
// get default version
var defaultVersionContent = httpClient
.GetStringAsync(defaultVersionUrl)
.GetStringAsync($"{defaultVersionUrl}{this.commonOptions.OryxSdkStorageAccountAccessToken}")
.Result;
string defaultVersion = null;

Просмотреть файл

@ -51,6 +51,7 @@ namespace Microsoft.Oryx.BuildScriptGeneratorCli.Options
options.PostBuildScriptPath = this.GetStringValue(SettingsKeys.PostBuildScriptPath);
options.PostBuildCommand = this.GetStringValue(SettingsKeys.PostBuildCommand);
options.OryxSdkStorageBaseUrl = this.GetStringValue(SettingsKeys.OryxSdkStorageBaseUrl);
options.OryxSdkStorageAccountAccessToken = this.GetStringValue(SettingsKeys.OryxSdkStorageAccountAccessToken);
options.AppType = this.GetStringValue(SettingsKeys.AppType);
options.BuildCommandsFileName = this.GetStringValue(SettingsKeys.BuildCommandsFileName);
options.CompressDestinationDir = this.GetBooleanValue(SettingsKeys.CompressDestinationDir);

Просмотреть файл

@ -64,6 +64,7 @@ namespace Microsoft.Oryx.BuildScriptGeneratorCli
public const string YarnTimeOutConfig = "YARN_TIMEOUT_CONFIG";
public const string PythonVirtualEnvironmentName = "VIRTUALENV_NAME";
public const string OryxSdkStorageBaseUrl = "ORYX_SDK_STORAGE_BASE_URL";
public const string OryxSdkStorageAccountAccessToken = "ORYX_SDK_STORAGE_ACCOUNT_ACCESS_TOKEN";
public const string AppType = "ORYX_APP_TYPE";
public const string BuildCommandsFileName = "BUILDCOMMANDS_FILE";
public const string DynamicInstallRootDir = "DYNAMIC_INSTALL_ROOT_DIR";

Просмотреть файл

@ -7,6 +7,7 @@ const SdkStorageBaseUrlKeyName string = "ORYX_SDK_STORAGE_BASE_URL"
const TestingSdkStorageUrlKeyName string = "ORYX_TEST_SDK_STORAGE_URL"
const DevSdkStorageBaseUrl string = "https://oryxsdksdev.blob.core.windows.net"
const SandboxSdkStorageBaseUrl string = "https://oryxsdkssandbox.blob.core.windows.net"
const PrivateSdkStorageBaseUrl string = "https://oryxsdksprivate.blob.core.windows.net"
const ProdSdkStorageBaseUrl string = "https://oryxsdksprod.blob.core.windows.net"
const ProdBackupSdkStorageBaseUrl string = "https://oryxsdksprodbackup.blob.core.windows.net"
const ProdSdkCdnStorageBaseUrl string = "https://oryx-cdn.microsoft.io"
@ -14,7 +15,7 @@ const DefaultVersionFileName string = "defaultVersion.txt"
const DefaultVersionFilePrefix string = "defaultVersion"
const DefaultVersionFileType string = "txt"
const VersionsToBuildFileName string = "versionsToBuild.txt"
const ContainerMetadataUrlFormat string = "{0}/{1}?restype=container&comp=list&include=metadata&marker={2}"
const ContainerMetadataUrlFormat string = "{0}/{1}?restype=container&comp=list&include=metadata&marker={2}&{3}"
const SdkDownloadSentinelFileName string = ".oryx-sdkdownload-sentinel"
const SdkVersionMetadataName string = "Sdk_version"
const LegacySdkVersionMetadataName string = "Version"

Просмотреть файл

@ -22,7 +22,8 @@ namespace Oryx.Integration.Tests
Environment.GetEnvironmentVariable(SdkStorageConstants.TestingSdkStorageUrlKeyName) ?? SdkStorageConstants.DevSdkStorageBaseUrl,
output,
testTempDirTestFixture,
repoRootDirTestFixture)
repoRootDirTestFixture,
string.Empty)
{
}
}

Просмотреть файл

@ -17,7 +17,7 @@ namespace Oryx.Integration.Tests
ITestOutputHelper output,
TestTempDirTestFixture testTempDirTestFixture,
RepoRootDirTestFixture repoRootDirTestFixture)
: base(SdkStorageConstants.ProdSdkStorageBaseUrl, output, testTempDirTestFixture, repoRootDirTestFixture)
: base(SdkStorageConstants.ProdSdkStorageBaseUrl, output, testTempDirTestFixture, repoRootDirTestFixture, string.Empty)
{
}
}

Просмотреть файл

@ -25,6 +25,7 @@ namespace Oryx.Integration.Tests
{
private readonly string _storageUrl;
private readonly string _repoRootDir;
private readonly string _sdkStorageAccountAccessToken;
private readonly string[] _debianFlavors =
{
@ -35,56 +36,58 @@ namespace Oryx.Integration.Tests
string storageUrl,
ITestOutputHelper output,
TestTempDirTestFixture testTempDirTestFixture,
RepoRootDirTestFixture repoRootDirTestFixture)
RepoRootDirTestFixture repoRootDirTestFixture,
string token)
: base(output, testTempDirTestFixture)
{
_storageUrl = storageUrl;
_repoRootDir = repoRootDirTestFixture.RepoRootDirPath;
_sdkStorageAccountAccessToken = token;
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void DotNetCoreContainer_HasExpectedListOfBlobs()
{
var platformName = "dotnet";
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void DotNetCoreContainer_HasExpectedDefaultVersion()
{
var platformName = "dotnet";
AssertExpectedDefaultVersion(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void GolangCoreContainer_HasExpectedListOfBlobs()
{
var platformName = "golang";
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void GolangContainer_HasExpectedDefaultVersion()
{
var platformName = "golang";
AssertExpectedDefaultVersion(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void PythonContainer_HasExpectedListOfBlobs()
{
var platformName = "python";
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void PythonContainer_HasExpectedDefaultVersion()
{
var platformName = "python";
AssertExpectedDefaultVersion(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void NodeJSContainer_HasExpectedListOfBlobs()
{
// Arrange & Act
@ -92,63 +95,63 @@ namespace Oryx.Integration.Tests
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void NodeJSContainer_HasExpectedDefaultVersion()
{
var platformName = "nodejs";
AssertExpectedDefaultVersion(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void PhpComposerCoreContainer_HasExpectedListOfBlobs()
{
var platformName = "php-composer";
AssertExpectedListOfBlobs(platformName, "php", "composer");
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void PhpContainer_HasExpectedListOfBlobs()
{
var platformName = "php";
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void PhpContainer_HasExpectedDefaultVersion()
{
var platformName = "php";
AssertExpectedDefaultVersion(platformName, "php");
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void PhpComposerContainer_HasExpectedDefaultVersion()
{
var platformName = "php-composer";
AssertExpectedDefaultVersion(platformName, "php", "composer");
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void RubyContainer_HasExpectedListOfBlobs()
{
var platformName = "ruby";
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void RubyContainer_HasExpectedDefaultVersion()
{
var platformName = "ruby";
AssertExpectedDefaultVersion(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void JavaContainer_HasExpectedListOfBlobs()
{
var platformName = "java";
AssertExpectedListOfBlobs(platformName, platformName);
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void JavaContainer_HasExpectedDefaultVersion()
{
var platformName = "java";
@ -156,13 +159,13 @@ namespace Oryx.Integration.Tests
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void MavenContainer_HasExpectedListOfBlobs()
{
AssertExpectedListOfBlobs("maven", "java", "maven");
}
[Fact]
[Fact(Skip = "Skipping test temporarily till we resolve the issue #1663008")]
public void MavenContainer_HasExpectedDefaultVersion()
{
AssertExpectedDefaultVersion("maven", "java", "maven");
@ -199,7 +202,7 @@ namespace Oryx.Integration.Tests
private XDocument GetMetadata(string platformName)
{
return ListBlobsHelper.GetAllBlobs(_storageUrl, platformName, _httpClient);
return ListBlobsHelper.GetAllBlobs(_storageUrl, platformName, _httpClient, _sdkStorageAccountAccessToken);
}
private List<string> GetVersionsFromContainer(string debianFlavor, string platformName)

Просмотреть файл

@ -22,6 +22,7 @@ steps:
DEV_STORAGE_SAS_TOKEN: $(DEV-STORAGE-SAS-TOKEN)
SANDBOX_STORAGE_SAS_TOKEN: $(SANDBOX-STORAGE-SAS-TOKEN)
PERSONAL_STORAGE_SAS_TOKEN: $(${{ upper(parameters.destinationSdkStorageAccountName) }}-PERSONAL-STORAGE-SAS-TOKEN)
PRIVATE_STORAGE_SAS_TOKEN: $(ORYX-SDK-PRIVATE-SAS-TOKEN)
inputs:
scriptPath: ./vsts/scripts/publishFilesToAzureStorage.sh
args: ${{ parameters.destinationSdkStorageAccountName }}

Просмотреть файл

@ -19,6 +19,8 @@ steps:
- task: ShellScript@2
displayName: 'Building platform binaries'
env:
DOTNET_PRIVATE_STORAGE_ACCOUNT_ACCESS_TOKEN: $(DotnetPrivateStorageAccountAccessToken)
inputs:
scriptPath: ./build/buildPlatformBinaries.sh
args: ${{ parameters.platformName }} ${{ parameters.debianFlavor }} https://${{ parameters.destinationSdkStorageAccountName }}.blob.core.windows.net

Просмотреть файл

@ -4,7 +4,7 @@
# Licensed under the MIT license.
# --------------------------------------------------------------------------------------------
set -ex
set -e
declare -r REPO_DIR=$( cd $( dirname "$0" ) && cd .. && cd .. && pwd )
source $REPO_DIR/platforms/__common.sh
@ -81,6 +81,8 @@ if [[ "$storageAccountUrl" == $SANDBOX_SDK_STORAGE_BASE_URL ]]; then
sasToken=$SANDBOX_STORAGE_SAS_TOKEN
elif [[ "$storageAccountUrl" == $DEV_SDK_STORAGE_BASE_URL ]]; then
sasToken=$DEV_STORAGE_SAS_TOKEN
elif [[ "$storageAccountUrl" == $PRIVATE_SDK_STORAGE_BASE_URL ]]; then
sasToken=$PRIVATE_STORAGE_SAS_TOKEN
# check if the personal sas token has been found in the oryx key vault
elif [[ "$PERSONAL_STORAGE_SAS_TOKEN" != "\$($storageAccountName-PERSONAL-STORAGE-SAS-TOKEN)" ]]; then
sasToken=$PERSONAL_STORAGE_SAS_TOKEN