diff options
author | Santiago Fernandez Madero <safern@microsoft.com> | 2022-03-11 04:02:29 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-11 04:02:29 +0300 |
commit | f00f03852455053b9e965b0e5343496599e17dd1 (patch) | |
tree | e672549922bfdccee7e13dde4b5f04e59a22113b | |
parent | 41e6ff4c8f6c12e7664174e84fa34c4175e02f3a (diff) |
[release/6.0] Run tests for internal azdo PRs (#65526)
* Run tests for internal azdo PRs
* PR Feedback
* Fix PGO jobs on official builds
We missed passing in the `isOfficialBuild` variable on the PGO jobs.
* Don't run upload-intermediate-artifacts-step.yml for PGO leg
* Fix .yml
Co-authored-by: Alexander Köplinger <alex.koeplinger@outlook.com>
-rw-r--r-- | eng/pipelines/common/global-build-job.yml | 3 | ||||
-rw-r--r-- | eng/pipelines/common/variables.yml | 4 | ||||
-rw-r--r-- | eng/pipelines/coreclr/templates/build-job.yml | 4 | ||||
-rw-r--r-- | eng/pipelines/coreclr/templates/helix-queues-setup.yml | 2 | ||||
-rw-r--r-- | eng/pipelines/installer/jobs/base-job.yml | 2 | ||||
-rw-r--r-- | eng/pipelines/libraries/base-job.yml | 5 | ||||
-rw-r--r-- | eng/pipelines/libraries/helix.yml | 10 | ||||
-rw-r--r-- | eng/pipelines/mono/templates/build-job.yml | 2 | ||||
-rw-r--r-- | eng/pipelines/mono/templates/generate-offsets.yml | 2 | ||||
-rw-r--r-- | eng/pipelines/mono/templates/workloads-build.yml | 2 | ||||
-rw-r--r-- | eng/pipelines/runtime-official.yml | 4 | ||||
-rw-r--r-- | eng/pipelines/runtime.yml | 1 |
12 files changed, 29 insertions, 12 deletions
diff --git a/eng/pipelines/common/global-build-job.yml b/eng/pipelines/common/global-build-job.yml index 7db10e91e68..c5d913a46ea 100644 --- a/eng/pipelines/common/global-build-job.yml +++ b/eng/pipelines/common/global-build-job.yml @@ -60,6 +60,9 @@ jobs: - ${{ parameters.dependsOn }} variables: + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - group: DotNet-HelixApi-Access + - name: _osParameter value: -os ${{ parameters.osGroup }} diff --git a/eng/pipelines/common/variables.yml b/eng/pipelines/common/variables.yml index e2ed01f836c..f302f02a38c 100644 --- a/eng/pipelines/common/variables.yml +++ b/eng/pipelines/common/variables.yml @@ -10,9 +10,9 @@ variables: value: 1000 - name: isOfficialBuild - value: ${{ and(ne(variables['System.TeamProject'], 'public'), ne(variables['Build.Reason'], 'PullRequest')) }} + value: ${{ and(eq(variables['Build.DefinitionName'], 'dotnet-runtime-official'), eq(variables['System.TeamProject'], 'internal'), ne(variables['Build.Reason'], 'PullRequest')) }} - name: isFullMatrix - value: ${{ and(eq(variables['System.TeamProject'], 'public'), ne(variables['Build.Reason'], 'PullRequest')) }} + value: ${{ ne(variables['Build.Reason'], 'PullRequest') }} # We only run evaluate paths on runtime, runtime-staging and runtime-community pipelines on PRs # keep in sync with /eng/pipelines/common/xplat-setup.yml diff --git a/eng/pipelines/coreclr/templates/build-job.yml b/eng/pipelines/coreclr/templates/build-job.yml index e94d630ba2e..cd2fb12ba1e 100644 --- a/eng/pipelines/coreclr/templates/build-job.yml +++ b/eng/pipelines/coreclr/templates/build-job.yml @@ -110,7 +110,7 @@ jobs: value: true - name: officialBuildIdArg value: '' - - ${{ if and(eq(variables['System.TeamProject'], 'internal'), ne(variables['Build.Reason'], 'PullRequest')) }}: + - ${{ if eq(parameters.isOfficialBuild, true) }}: - name: officialBuildIdArg value: '/p:OfficialBuildId=$(Build.BuildNumber)' - name: enforcePgoArg @@ -298,7 +298,7 @@ jobs: SecretsFilter: 'dotnetfeed-storage-access-key-1,microsoft-symbol-server-pat,symweb-symbol-server-pat' # Save packages using the prepare-signed-artifacts format. - - ${{ if and(eq(parameters.isOfficialBuild, true), ne(parameters.testGroup, 'clrTools')) }}: + - ${{ if and(eq(parameters.isOfficialBuild, true), ne(parameters.testGroup, 'clrTools'), eq(parameters.pgoType, '')) }}: - template: /eng/pipelines/common/upload-intermediate-artifacts-step.yml parameters: name: ${{ parameters.platform }} diff --git a/eng/pipelines/coreclr/templates/helix-queues-setup.yml b/eng/pipelines/coreclr/templates/helix-queues-setup.yml index be38b2b327d..c48ea2ab2e8 100644 --- a/eng/pipelines/coreclr/templates/helix-queues-setup.yml +++ b/eng/pipelines/coreclr/templates/helix-queues-setup.yml @@ -130,7 +130,7 @@ jobs: - Windows.81.Amd64 - Windows.10.Amd64 - Windows.10.Amd64.Core - - (Windows.Nano.1809.Amd64.Open)windows.10.amd64.serverrs5.open@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504 + - (Windows.Nano.1809.Amd64)windows.10.amd64.serverrs5@mcr.microsoft.com/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-08e8e40-20200107182504 # windows x86 - ${{ if eq(parameters.platform, 'windows_x86') }}: diff --git a/eng/pipelines/installer/jobs/base-job.yml b/eng/pipelines/installer/jobs/base-job.yml index 680266566c3..84dec3be206 100644 --- a/eng/pipelines/installer/jobs/base-job.yml +++ b/eng/pipelines/installer/jobs/base-job.yml @@ -356,7 +356,7 @@ jobs: zipSources: false feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json continueOnError: false - condition: and(succeeded(), in(variables['SignType'], 'real', 'test')) + condition: and(succeeded(), in(variables['SignType'], 'real', 'test'), eq(${{ parameters.isOfficialBuild }}, true)) - checkout: self clean: true diff --git a/eng/pipelines/libraries/base-job.yml b/eng/pipelines/libraries/base-job.yml index 9c5cff7cc5e..63ef5c4e9ac 100644 --- a/eng/pipelines/libraries/base-job.yml +++ b/eng/pipelines/libraries/base-job.yml @@ -41,6 +41,9 @@ jobs: helixRepo: dotnet/runtime pool: ${{ parameters.pool }} variables: + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - group: DotNet-HelixApi-Access + - _buildScriptFileName: build - _msbuildCommonParameters: '' @@ -84,7 +87,7 @@ jobs: - ${{ if eq(parameters.isOfficialAllConfigurations, true) }}: - librariesBuildArtifactName: 'libraries_bin_official_allconfigurations' - - ${{ if eq(parameters.isOfficialBuild, 'true') }}: + - ${{ if eq(parameters.isOfficialBuild, true) }}: - _msbuildCommonParameters: /p:OfficialBuildId=$(Build.BuildNumber) - _runtimeArtifactName: '' diff --git a/eng/pipelines/libraries/helix.yml b/eng/pipelines/libraries/helix.yml index a8b6517efeb..cb3b70890fd 100644 --- a/eng/pipelines/libraries/helix.yml +++ b/eng/pipelines/libraries/helix.yml @@ -26,7 +26,6 @@ steps: /p:TestScope=${{ parameters.testScope }} /p:TestRunNamePrefixSuffix=${{ parameters.testRunNamePrefixSuffix }} /p:HelixBuild=$(Build.BuildNumber) - /p:Creator=${{ parameters.creator }} ${{ parameters.extraHelixArguments }} /bl:$(Build.SourcesDirectory)/artifacts/log/$(_BuildConfig)/SendToHelix.binlog displayName: Send to Helix @@ -34,5 +33,12 @@ steps: continueOnError: ${{ eq(parameters.shouldContinueOnError, true) }} env: SYSTEM_ACCESSTOKEN: $(System.AccessToken) # We need to set this env var to publish helix results to Azure Dev Ops - HelixTargetQueues: ${{ join('+', parameters.helixQueues) }} # Pass queues to MSBuild as env var to avoid need of escaping them _Scenarios: ${{ join(',', parameters.scenarios) }} # Pass scenarios to MSBuild as env var to avoid need of escaping comma separated list + + ${{ if eq(variables['System.TeamProject'], 'internal') }}: + HelixAccessToken: $(HelixApiAccessToken) + HelixTargetQueues: ${{ replace(lower(join('+', parameters.helixQueues)), '.open', '') }} + Creator: '' + ${{ if eq(variables['System.TeamProject'], 'public') }}: + HelixTargetQueues: ${{ join('+', parameters.helixQueues) }} + Creator: ${{ parameters.creator }} diff --git a/eng/pipelines/mono/templates/build-job.yml b/eng/pipelines/mono/templates/build-job.yml index bdb15a09a66..878cd240367 100644 --- a/eng/pipelines/mono/templates/build-job.yml +++ b/eng/pipelines/mono/templates/build-job.yml @@ -65,7 +65,7 @@ jobs: value: '+mono.mscordbi' - name: darwinFrameworks value: '' - - ${{ if and(eq(variables['System.TeamProject'], 'internal'), ne(variables['Build.Reason'], 'PullRequest')) }}: + - ${{ if eq(parameters.isOfficialBuild, true) }}: - name: officialBuildIdArg value: '/p:officialBuildId=$(Build.BuildNumber)' - ${{ if and(eq(parameters.osSubgroup, '_musl'), eq(parameters.osGroup, 'Linux')) }}: diff --git a/eng/pipelines/mono/templates/generate-offsets.yml b/eng/pipelines/mono/templates/generate-offsets.yml index cbb05aaafff..ba3b2505082 100644 --- a/eng/pipelines/mono/templates/generate-offsets.yml +++ b/eng/pipelines/mono/templates/generate-offsets.yml @@ -41,7 +41,7 @@ jobs: value: ${{ parameters.osSubGroup }} - name: officialBuildIdArg value: '' - - ${{ if and(eq(variables['System.TeamProject'], 'internal'), ne(variables['Build.Reason'], 'PullRequest')) }}: + - ${{ if eq(parameters.isOfficialBuild, true) }}: - name: officialBuildIdArg value: '/p:officialBuildId=$(Build.BuildNumber)' - name: osOverride diff --git a/eng/pipelines/mono/templates/workloads-build.yml b/eng/pipelines/mono/templates/workloads-build.yml index a6b6e759306..3071edef691 100644 --- a/eng/pipelines/mono/templates/workloads-build.yml +++ b/eng/pipelines/mono/templates/workloads-build.yml @@ -39,7 +39,7 @@ jobs: variables: - name: officialBuildIdArg value: '' - - ${{ if and(eq(variables['System.TeamProject'], 'internal'), ne(variables['Build.Reason'], 'PullRequest')) }}: + - ${{ if eq(parameters.isOfficialBuild, true) }}: - name: officialBuildIdArg value: '/p:OfficialBuildId=$(Build.BuildNumber)' - name: SignType diff --git a/eng/pipelines/runtime-official.yml b/eng/pipelines/runtime-official.yml index cee8a4483fe..8dd4071476e 100644 --- a/eng/pipelines/runtime-official.yml +++ b/eng/pipelines/runtime-official.yml @@ -159,6 +159,8 @@ stages: - tvOS_arm64 - iOS_arm64 - MacCatalyst_x64 + jobParameters: + isOfficialBuild: ${{ variables.isOfficialBuild }} # # Build Mono release AOT cross-compilers @@ -374,6 +376,8 @@ stages: - windows_x86 - Linux_x64 jobParameters: + isOfficialBuild: ${{ variables.isOfficialBuild }} + signBinaries: false testGroup: innerloop pgoType: 'PGO' diff --git a/eng/pipelines/runtime.yml b/eng/pipelines/runtime.yml index 0fca635b793..2cc107b6215 100644 --- a/eng/pipelines/runtime.yml +++ b/eng/pipelines/runtime.yml @@ -210,6 +210,7 @@ jobs: - iOS_arm64 - MacCatalyst_x64 jobParameters: + isOfficialBuild: ${{ variables.isOfficialBuild }} condition: >- or( eq(dependencies.evaluate_paths.outputs['SetPathVars_mono.containsChange'], true), |