@@ -31,9 +31,6 @@ parameters:
31
31
- name : OsVmImage
32
32
type : string
33
33
default : ubuntu-22.04
34
- - name : Os
35
- type : string
36
- default : linux
37
34
# This parameter is only necessary if there are multiple invocations of this template within the SAME STAGE.
38
35
# When that occurs, provide a name other than the default value.
39
36
- name : GenerateJobName
@@ -42,31 +39,15 @@ parameters:
42
39
- name : PreGenerationSteps
43
40
type : stepList
44
41
default : []
45
- # Mappings to OS name required at template compile time by 1es pipeline templates
46
- - name : Pools
47
- type : object
48
- default :
49
- - name : LinuxPool
50
- os : linux
51
- - name : LinuxNextPool
52
- os : linux
53
- - name : WindowsPool
54
- os : windows
55
- - name : MacPool
56
- os : macOS
57
42
58
43
jobs :
59
44
- job : ${{ parameters.GenerateJobName }}
60
45
variables :
61
- - template : /eng/pipelines/templates/variables/image.yml
62
- - name : skipComponentGovernanceDetection
63
- value : true
64
- - name : displayNameFilter
65
- value : $[ coalesce(variables.jobMatrixFilter, '.*') ]
46
+ skipComponentGovernanceDetection : true
47
+ displayNameFilter : $[ coalesce(variables.jobMatrixFilter, '.*') ]
66
48
pool :
67
49
name : ${{ parameters.Pool }}
68
50
vmImage : ${{ parameters.OsVmImage }}
69
- os : ${{ parameters.Os }}
70
51
${{ if parameters.DependsOn }} :
71
52
dependsOn : ${{ parameters.DependsOn }}
72
53
steps :
@@ -84,56 +65,52 @@ jobs:
84
65
- ${{ parameters.PreGenerationSteps }}
85
66
86
67
- ${{ each config in parameters.MatrixConfigs }} :
87
- - ${{ each pool in parameters.Pools }} :
88
- - ${{ if eq(config.GenerateVMJobs, 'true') }} :
89
- - task : Powershell@2
90
- inputs :
91
- pwsh : true
92
- filePath : eng/common/scripts/job-matrix/Create-JobMatrix.ps1
93
- arguments : >
94
- -ConfigPath ${{ config.Path }}
95
- -Selection ${{ config.Selection }}
96
- -DisplayNameFilter '$(displayNameFilter)'
97
- -Filters '${{ join(''',''', parameters.MatrixFilters) }}', 'container=^$', 'SupportedClouds=^$|${{ parameters.CloudConfig.Cloud }}', 'Pool=.*${{ pool.name }}$'
98
- -Replace '${{ join(''',''', parameters.MatrixReplace) }}'
99
- -NonSparseParameters '${{ join(''',''', config.NonSparseParameters) }}'
100
- displayName : Create ${{ pool.name }} Matrix ${{ config.Name }}
101
- name : vm_job_matrix_${{ config.Name }}_${{ pool.name }}
68
+ - ${{ if eq(config.GenerateVMJobs, 'true') }} :
69
+ - task : Powershell@2
70
+ inputs :
71
+ pwsh : true
72
+ filePath : eng/common/scripts/job-matrix/Create-JobMatrix.ps1
73
+ arguments : >
74
+ -ConfigPath ${{ config.Path }}
75
+ -Selection ${{ config.Selection }}
76
+ -DisplayNameFilter '$(displayNameFilter)'
77
+ -Filters '${{ join(''',''', parameters.MatrixFilters) }}','container=^$','SupportedClouds=^$|${{ parameters.CloudConfig.Cloud }}'
78
+ -Replace '${{ join(''',''', parameters.MatrixReplace) }}'
79
+ -NonSparseParameters '${{ join(''',''', config.NonSparseParameters) }}'
80
+ displayName : Generate VM Job Matrix ${{ config.Name }}
81
+ name : generate_vm_job_matrix_${{ config.Name }}
102
82
103
- - ${{ if eq(config.GenerateContainerJobs, 'true') }} :
104
- - task : Powershell@2
105
- inputs :
106
- pwsh : true
107
- filePath : eng/common/scripts/job-matrix/Create-JobMatrix.ps1
108
- arguments : >
109
- -ConfigPath ${{ config.Path }}
110
- -Selection ${{ config.Selection }}
111
- -DisplayNameFilter '$(displayNameFilter)'
112
- -Filters '${{ join(''',''', parameters.MatrixFilters) }}', 'container=^$ ', 'SupportedClouds=^$|${{ parameters.CloudConfig.Cloud }}', 'Pool=.*${{ pool.name }}$ '
113
- -NonSparseParameters '${{ join(''',''', config.NonSparseParameters) }}'
114
- displayName : Create ${{ pool.name }} Container Matrix ${{ config.Name }}
115
- name : container_job_matrix_ ${{ config.Name }}_${{ pool.name }}
83
+ - ${{ if eq(config.GenerateContainerJobs, 'true') }} :
84
+ - task : Powershell@2
85
+ inputs :
86
+ pwsh : true
87
+ filePath : eng/common/scripts/job-matrix/Create-JobMatrix.ps1
88
+ arguments : >
89
+ -ConfigPath ${{ config.Path }}
90
+ -Selection ${{ config.Selection }}
91
+ -DisplayNameFilter '$(displayNameFilter)'
92
+ -Filters '${{ join(''',''', parameters.MatrixFilters) }}', 'container=.* ', 'SupportedClouds=^$|${{ parameters.CloudConfig.Cloud }}'
93
+ -NonSparseParameters '${{ join(''',''', config.NonSparseParameters) }}'
94
+ displayName : Generate Container Job Matrix
95
+ name : generate_container_job_matrix_ ${{ config.Name }}
116
96
117
97
- ${{ each config in parameters.MatrixConfigs }} :
118
- - ${{ each pool in parameters.Pools }} :
119
- - ${{ if eq(config.GenerateVMJobs, 'true') }} :
120
- - template : ${{ parameters.JobTemplatePath }}
121
- parameters :
122
- UsePlatformContainer : false
123
- OSName : ${{ pool.os }}
124
- Matrix : dependencies.${{ parameters.GenerateJobName }}.outputs['vm_job_matrix_${{ config.Name }}_${{ pool.name }}.matrix']
125
- DependsOn : ${{ parameters.GenerateJobName }}
126
- CloudConfig : ${{ parameters.CloudConfig }}
127
- ${{ each param in parameters.AdditionalParameters }} :
128
- ${{ param.key }} : ${{ param.value }}
98
+ - ${{ if eq(config.GenerateVMJobs, 'true') }} :
99
+ - template : ${{ parameters.JobTemplatePath }}
100
+ parameters :
101
+ UsePlatformContainer : false
102
+ Matrix : dependencies.${{ parameters.GenerateJobName }}.outputs['generate_vm_job_matrix_${{ config.Name }}.matrix']
103
+ DependsOn : ${{ parameters.GenerateJobName }}
104
+ CloudConfig : ${{ parameters.CloudConfig }}
105
+ ${{ each param in parameters.AdditionalParameters }} :
106
+ ${{ param.key }} : ${{ param.value }}
129
107
130
- - ${{ if eq(config.GenerateContainerJobs, 'true') }} :
131
- - template : ${{ parameters.JobTemplatePath }}
132
- parameters :
133
- UsePlatformContainer : true
134
- OSName : ${{ pool.os }}
135
- Matrix : dependencies.${{ parameters.GenerateJobName }}.outputs['vm_job_matrix_${{ config.Name }}_${{ pool.name }}.matrix']
136
- DependsOn : ${{ parameters.GenerateJobName }}
137
- CloudConfig : ${{ parameters.CloudConfig }}
138
- ${{ each param in parameters.AdditionalParameters }} :
139
- ${{ param.key }} : ${{ param.value }}
108
+ - ${{ if eq(config.GenerateContainerJobs, 'true') }} :
109
+ - template : ${{ parameters.JobTemplatePath }}
110
+ parameters :
111
+ UsePlatformContainer : true
112
+ Matrix : dependencies.${{ parameters.GenerateJobName }}.outputs['generate_container_job_matrix_${{ config.Name }}.matrix']
113
+ DependsOn : ${{ parameters.GenerateJobName }}
114
+ CloudConfig : ${{ parameters.CloudConfig }}
115
+ ${{ each param in parameters.AdditionalParameters }} :
116
+ ${{ param.key }} : ${{ param.value }}
0 commit comments