From 61a7ec7347804b96e1f123bb87b1bb8f43363397 Mon Sep 17 00:00:00 2001 From: Ella Hathaway <67609881+ellahathaway@users.noreply.github.com> Date: Mon, 27 Nov 2023 11:27:55 -0800 Subject: [PATCH] Download and compare linux-musl-x64 MSFT sdk (#17823) --- .../common/templates/job/source-build-build-tarball.yml | 9 +++++++-- src/SourceBuild/tarball/content/Directory.Build.props | 1 + 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/SourceBuild/Arcade/eng/common/templates/job/source-build-build-tarball.yml b/src/SourceBuild/Arcade/eng/common/templates/job/source-build-build-tarball.yml index 9e67adb4d..c8756326e 100644 --- a/src/SourceBuild/Arcade/eng/common/templates/job/source-build-build-tarball.yml +++ b/src/SourceBuild/Arcade/eng/common/templates/job/source-build-build-tarball.yml @@ -85,7 +85,7 @@ jobs: - ${{ if ne(parameters.excludeSdkContentTests, 'true') }}: - download: ${{ parameters.installerBuildResourceId }} artifact: BlobArtifacts - patterns: '**/dotnet-sdk-+([0-9]).+([0-9]).+([0-9])?(-@(preview|rc|rtm)*)-linux-${{ parameters.architecture }}.tar.gz' + patterns: '**/dotnet-sdk-+([0-9]).+([0-9]).+([0-9])?(-@(preview|rc|rtm)*)-linux*-${{ parameters.architecture }}.tar.gz' displayName: Download MSFT sdk Tarball - ${{ if eq(parameters.usePreviousArtifacts, 'true') }}: @@ -185,7 +185,12 @@ jobs: if [[ '${{ parameters.excludeSdkContentTests}}' != 'true' ]]; then dockerVolumeArgs+=" -v $(PIPELINE.WORKSPACE)/${{ parameters.installerBuildResourceId }}/BlobArtifacts/:/BlobArtifacts" - msftSdkTarballName=$(find "$(PIPELINE.WORKSPACE)/${{ parameters.installerBuildResourceId }}/BlobArtifacts/" -name "dotnet-sdk-*-linux-${{ parameters.architecture }}.tar.gz" -exec basename {} \;) + platform="linux" + docker run --rm $(_Container) /bin/sh -c "cat /etc/os-release | grep -q alpine" + if [[ $? == 0 ]]; then + platform="$platform-musl" + fi + msftSdkTarballName=$(find "$(PIPELINE.WORKSPACE)/${{ parameters.installerBuildResourceId }}/BlobArtifacts/" -name "dotnet-sdk-*-$platform-${{ parameters.architecture }}.tar.gz" -exec basename {} \;) dockerEnvArgs+=" -e SMOKE_TESTS_MSFT_SDK_TARBALL_PATH=/BlobArtifacts/$msftSdkTarballName" fi diff --git a/src/SourceBuild/tarball/content/Directory.Build.props b/src/SourceBuild/tarball/content/Directory.Build.props index 2f4a8ee71..0bd228850 100644 --- a/src/SourceBuild/tarball/content/Directory.Build.props +++ b/src/SourceBuild/tarball/content/Directory.Build.props @@ -174,6 +174,7 @@ freebsd-$(Platform) osx-$(Platform) linux-$(Platform) + linux-musl-$(Platform) win-$(Platform) $(PortableRid)