From 35945c9015472fb0c2feb019c6cf9dc9479c7e9e Mon Sep 17 00:00:00 2001 From: Liu Shilong Date: Mon, 29 Aug 2022 11:26:15 +0800 Subject: [PATCH] [ci] Update reproducible build related pipeline. (#11810) --- .azure-pipelines/azure-pipelines-repd-build-variables.yml | 2 +- .azure-pipelines/official-build.yml | 2 +- azure-pipelines.yml | 5 +---- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/.azure-pipelines/azure-pipelines-repd-build-variables.yml b/.azure-pipelines/azure-pipelines-repd-build-variables.yml index 1bd897dafb92..af77e97e2ff0 100644 --- a/.azure-pipelines/azure-pipelines-repd-build-variables.yml +++ b/.azure-pipelines/azure-pipelines-repd-build-variables.yml @@ -1,6 +1,6 @@ variables: ${{ if eq(variables['Build.Reason'],'PullRequest') }}: - VERSION_CONTROL_OPTIONS: 'SONIC_VERSION_CONTROL_COMPONENTS=$([ "$(System.PullRequest.TargetBranch)" != "master" ] && echo deb,py2,py3,web,git,docker)' + VERSION_CONTROL_OPTIONS: 'SONIC_VERSION_CONTROL_COMPONENTS=$([[ "$(System.PullRequest.TargetBranch)" =~ ^20[2-9][0-9]{3}$ ]] && echo deb,py2,py3,web,git,docker)' ${{ elseif ne(variables['Build.SourceBranchName'],'master') }}: VERSION_CONTROL_OPTIONS: 'SONIC_VERSION_CONTROL_COMPONENTS=deb,py2,py3,web,git,docker' ${{ else }}: diff --git a/.azure-pipelines/official-build.yml b/.azure-pipelines/official-build.yml index ee99d7ca3f28..c73124f2e91f 100644 --- a/.azure-pipelines/official-build.yml +++ b/.azure-pipelines/official-build.yml @@ -38,7 +38,7 @@ stages: variables: - name: CACHE_MODE value: wcache - - template: azure-pipelines-repd-build-variables.yml + - template: azure-pipelines-repd-build-variables.yml@buildimage jobs: - template: azure-pipelines-build.yml parameters: diff --git a/azure-pipelines.yml b/azure-pipelines.yml index b9653c2bc8cd..5876080411a2 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -38,10 +38,7 @@ resources: variables: - template: .azure-pipelines/azure-pipelines-repd-build-variables.yml@buildimage -- ${{ if eq(variables['Build.Reason'], 'PullRequest') }}: - - template: .azure-pipelines/template-variables.yml -- ${{ else }}: - - template: .azure-pipelines/template-variables.yml@buildimage +- template: .azure-pipelines/template-variables.yml@buildimage - name: CACHE_MODE value: rcache - name: ENABLE_FIPS