diff --git a/eng/ci/templates/official/jobs/build-test.yml b/eng/ci/templates/official/jobs/build-test.yml index 0463da773..ced541808 100644 --- a/eng/ci/templates/official/jobs/build-test.yml +++ b/eng/ci/templates/official/jobs/build-test.yml @@ -60,14 +60,6 @@ jobs: Install-Dotnet displayName: 'Install .NET 6.0 and 3.1' - - pwsh: | - Import-Module "./eng/scripts/modules/pipelineUtilities.psm1" -Force - Install-SBOMUtil -SBOMUtilSASUrl $env:SBOMUtilSASUrl - env: - SBOMUtilSASUrl: $(SBOMUtilSASUrl) - condition: eq(variables['IsReleaseBuild'], 'true') - displayName: 'Install SBOM ManifestTool' - - task: NuGetToolInstaller@1 inputs: versionSpec: diff --git a/eng/scripts/modules/pipelineUtilities.psm1 b/eng/scripts/modules/pipelineUtilities.psm1 index 9a2c75a77..8fde5689f 100644 --- a/eng/scripts/modules/pipelineUtilities.psm1 +++ b/eng/scripts/modules/pipelineUtilities.psm1 @@ -7,48 +7,6 @@ using namespace System.Runtime.InteropServices -$DLL_NAME = "Microsoft.ManifestTool.dll" -$MANIFESTOOLNAME = "ManifestTool" -$MANIFESTOOL_DIRECTORY = Join-Path $PSScriptRoot $MANIFESTOOLNAME -$MANIFEST_TOOL_PATH = "$MANIFESTOOL_DIRECTORY/$DLL_NAME" - -function Get-ManifestToolPath -{ - if (Test-Path $MANIFEST_TOOL_PATH) - { - return $MANIFEST_TOOL_PATH - } - throw "The SBOM Manifest Tool is not installed. Please run Install-SBOMUtil -SBOMUtilSASUrl " -} - -function Install-SBOMUtil -{ - param( - [string] - $SBOMUtilSASUrl - ) - - if ([string]::IsNullOrEmpty($SBOMUtilSASUrl)) - { - throw "The `$SBOMUtilSASUrl parameter cannot be null or empty when specifying `$(addSBOM)" - } - - Write-Host "Installing $MANIFESTOOLNAME..." - Remove-Item -Recurse -Force $MANIFESTOOL_DIRECTORY -ErrorAction Ignore - - Invoke-RestMethod -Uri $SBOMUtilSASUrl -OutFile "$MANIFESTOOL_DIRECTORY.zip" - Expand-Archive "$MANIFESTOOL_DIRECTORY.zip" -DestinationPath $MANIFESTOOL_DIRECTORY - - if (-not (Test-Path $MANIFEST_TOOL_PATH)) - { - throw "$MANIFESTOOL_DIRECTORY does not contain '$DLL_NAME'" - } - - Write-Host 'Done.' - - return $MANIFEST_TOOL_PATH -} - $DotnetSDKVersionRequirements = @{ # .NET SDK 3.1 is required by the Microsoft.ManifestTool.dll tool