Skip to content

Commit 2fdc85d

Browse files
authored
Use a single pipeline with runtime conditioned jobs in PRs (dotnet#1473)
* Use a single pipeline with runtime conditioned jobs in PRs * PR Feedback * Disable long running tests checked runtime
1 parent 16e325d commit 2fdc85d

20 files changed

+475
-586
lines changed

eng/pipelines/common/variables.yml

+8-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
11
variables:
22
- name: isOfficialBuild
3-
value: ${{ and(ne(variables['System.TeamProject'], 'public'), notIn(variables['Build.Reason'], 'PullRequest')) }}
3+
value: ${{ and(ne(variables['System.TeamProject'], 'public'), ne(variables['Build.Reason'], 'PullRequest')) }}
4+
- name: isFullMatrix
5+
value: ${{ and(eq(variables['System.TeamProject'], 'public'), ne(variables['Build.Reason'], 'PullRequest')) }}
6+
- name: debugOnPrReleaseOnRolling
7+
${{ if ne(variables['Build.Reason'], 'PullRequest') }}:
8+
value: Release
9+
${{ if eq(variables['Build.Reason'], 'PullRequest') }}:
10+
value: Debug

eng/pipelines/common/xplat-setup.yml

-7
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,6 @@ jobs:
1212
- template: ${{ coalesce(parameters.helixQueuesTemplate, parameters.jobTemplate) }}
1313
parameters:
1414
variables:
15-
- name: _containsCoreClrChange
16-
value: $[ dependencies.checkout.outputs['SetPathVars_coreclr.containsChange'] ]
17-
- name: _containsLibrariesChange
18-
value: $[ dependencies.checkout.outputs['SetPathVars_libraries.containsChange'] ]
19-
- name: _containsInstallerChange
20-
value: $[ dependencies.checkout.outputs['SetPathVars_installer.containsChange'] ]
21-
2215
- ${{ if eq(parameters.osGroup, 'Windows_NT') }}:
2316
- name: archiveExtension
2417
value: '.zip'

eng/pipelines/coreclr/pr.yml

-216
This file was deleted.

eng/pipelines/coreclr/templates/build-job.yml

+2
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ parameters:
1414
variables: {}
1515
pool: ''
1616
isOfficialBuild: false
17+
condition: true
1718

1819
### Product build
1920
jobs:
@@ -29,6 +30,7 @@ jobs:
2930
enableMicrobuild: true
3031
stagedBuild: ${{ parameters.stagedBuild }}
3132
pool: ${{ parameters.pool }}
33+
condition: ${{ parameters.condition }}
3234

3335
# Compute job name from template parameters
3436
name: ${{ format('coreclr_product_build_{0}{1}_{2}_{3}', parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.buildConfig) }}

eng/pipelines/coreclr/templates/format-job.yml

+2
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ parameters:
99
stagedBuild: false
1010
variables: {}
1111
pool: ''
12+
condition: true
1213

1314
### Format job
1415
jobs:
@@ -27,6 +28,7 @@ jobs:
2728
helixType: 'format'
2829
pool: ${{ parameters.pool }}
2930
variables: ${{ parameters.variables }}
31+
condition: ${{ parameters.condition }}
3032
steps:
3133
- task: UseDotNet@2
3234
# This should match what jitutils YML uses to build.

eng/pipelines/coreclr/templates/helix-queues-setup.yml

+11-11
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
- ${{ if eq(parameters.platform, 'Linux_arm64') }}:
3333
- ${{ if eq(variables['System.TeamProject'], 'public') }}:
3434
- (Ubuntu.1804.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:ubuntu-18.04-helix-arm64v8-a45aeeb-20190620155855
35-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
35+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
3636
- (Debian.9.Arm64.Open)[email protected]/dotnet-buildtools/prereqs:debian-9-helix-arm64v8-74c9941-20190620155840
3737
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
3838
- (Debian.9.Arm64)[email protected]/dotnet-buildtools/prereqs:debian-9-helix-arm64v8-74c9941-20190620155840
@@ -56,9 +56,9 @@ jobs:
5656

5757
# Linux x64
5858
- ${{ if eq(parameters.platform, 'Linux_x64') }}:
59-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
59+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
6060
- Ubuntu.1804.Amd64.Open
61-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
61+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
6262
- Debian.9.Amd64.Open
6363
- Ubuntu.1604.Amd64.Open
6464
- Ubuntu.1804.Amd64.Open
@@ -74,9 +74,9 @@ jobs:
7474

7575
# OSX x64
7676
- ${{ if eq(parameters.platform, 'OSX_x64') }}:
77-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
77+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
7878
- OSX.1013.Amd64.Open
79-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
79+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
8080
- OSX.1013.Amd64.Open
8181
- OSX.1014.Amd64.Open
8282
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
@@ -85,9 +85,9 @@ jobs:
8585

8686
# Windows_NT x64
8787
- ${{ if eq(parameters.platform, 'Windows_NT_x64') }}:
88-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
88+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
8989
- Windows.10.Amd64.Open
90-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
90+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
9191
- (Windows.Nano.1809.Amd64.Open)[email protected]/dotnet-buildtools/prereqs:nanoserver-1809-helix-amd64-61052b7-20190723211353
9292
- Windows.7.Amd64.Open
9393
- Windows.81.Amd64.Open
@@ -101,9 +101,9 @@ jobs:
101101

102102
# Windows_NT x86
103103
- ${{ if eq(parameters.platform, 'Windows_NT_x86') }}:
104-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
104+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
105105
- Windows.10.Amd64.Open
106-
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
106+
- ${{ if and(eq(variables['System.TeamProject'], 'public'), notIn(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
107107
- Windows.7.Amd64.Open
108108
- Windows.81.Amd64.Open
109109
- Windows.10.Amd64.Open
@@ -119,8 +119,8 @@ jobs:
119119
# https://github.com/dotnet/runtime/issues/1097
120120
# https://github.com/dotnet/runtime/issues/1663
121121
# https://github.com/dotnet/core-eng/issues/8490
122-
# - ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'corefx')) }}:
123-
# - Windows.10.Arm64.Open
122+
# - ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.jobParameters.helixQueueGroup, 'pr', 'ci', 'libraries')) }}:
123+
# - Windows.10.Arm64.Open
124124
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
125125
- Windows.10.Arm64
126126

eng/pipelines/coreclr/templates/run-test-job.yml

+1
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ jobs:
4343
liveLibrariesBuildConfig: ${{ parameters.liveLibrariesBuildConfig }}
4444
helixType: 'build/tests/'
4545
pool: ${{ parameters.pool }}
46+
condition: ${{ parameters.condition }}
4647

4748
# Test jobs should continue on error for internal builds
4849
${{ if eq(variables['System.TeamProject'], 'internal') }}:

eng/pipelines/coreclr/templates/xplat-pipeline-job.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ parameters:
1717
pool: ''
1818

1919
# arcade-specific parameters
20-
condition: ''
20+
condition: true
2121
continueOnError: false
2222
dependsOn: ''
2323
displayName: ''
@@ -43,7 +43,7 @@ jobs:
4343
pool: ${{ parameters.pool }}
4444

4545
# arcade-specific parameters
46-
condition: ${{ parameters.condition }}
46+
condition: and(succeeded(), ${{ parameters.condition }})
4747
continueOnError: ${{ parameters.continueOnError }}
4848
dependsOn: ${{ parameters.dependsOn }}
4949
displayName: ${{ parameters.displayName }}

0 commit comments

Comments
 (0)