From b4a37194f507e6edee649e65411968e87092f87e Mon Sep 17 00:00:00 2001 From: Pranav K Date: Thu, 2 Jul 2020 07:02:27 -0700 Subject: [PATCH] Skip component governance for linux musl x64 (#23592) * Skip component governance for linux musl x64 * Use parameters * jazz --- .azure/pipelines/ci.yml | 1 + .azure/pipelines/jobs/default-build.yml | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.azure/pipelines/ci.yml b/.azure/pipelines/ci.yml index 86946e879b..5f44f14fc3 100644 --- a/.azure/pipelines/ci.yml +++ b/.azure/pipelines/ci.yml @@ -449,6 +449,7 @@ stages: $(_InternalRuntimeDownloadArgs) installNodeJs: false installJdk: false + skipComponentGovernanceDetection: true artifacts: - name: Linux_musl_x64_Logs path: artifacts/log/ diff --git a/.azure/pipelines/jobs/default-build.yml b/.azure/pipelines/jobs/default-build.yml index 57c61890a5..f851f512f2 100644 --- a/.azure/pipelines/jobs/default-build.yml +++ b/.azure/pipelines/jobs/default-build.yml @@ -35,7 +35,8 @@ # Specifies what directory to run build.sh/cmd # buildScript: string # Specifies the build script to run. Defaults to build.sh or build.cmd. - +# skipComponentGovernanceDetection: boolean +# Determines if component governance detection can be skipped # # See https://docs.microsoft.com/en-us/vsts/pipelines/yaml-schema for details # @@ -60,6 +61,7 @@ parameters: installJdk: true timeoutInMinutes: 180 useHostedUbuntu: true + skipComponentGovernanceDetection: false # We need longer than the default amount of 5 minutes to upload our logs/artifacts. (We currently take around 5 mins in the best case). # This makes sure we have time to upload everything in the case of a build timeout - really important for investigating a build @@ -240,7 +242,7 @@ jobs: continueOnError: true condition: always() - - ${{ if and(startsWith(parameters.jobDisplayName, 'Build:'), ne(variables['skipComponentGovernanceDetection'], 'true'), notin(variables['Build.Reason'], 'PullRequest')) }}: + - ${{ if and(startsWith(parameters.jobDisplayName, 'Build:'), ne(parameters.skipComponentGovernanceDetection, 'true'), notin(variables['Build.Reason'], 'PullRequest')) }}: - task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0 condition: and(succeeded(), ne(variables['CG_RAN'], 'true')) displayName: 'Component Detection'