forked from microsoft/azure-pipelines-agent
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vsts.ci.yml
206 lines (177 loc) Β· 6.39 KB
/
.vsts.ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
pr:
branches:
include:
- '*'
paths:
exclude:
- 'docs/*'
resources:
containers:
- container: dotnetcore_arm
image: huangtingluo/azure-pipelines-agent-eng:arm
- container: dotnetcore_centos6
image: huangtingluo/azure-pipelines-agent-eng:centos6
jobs:
################################################################################
- job: build_windows_x64_agent
################################################################################
displayName: Windows Agent (x64)
pool:
vmImage: vs2017-win2016
steps:
# Steps template for windows platform
- template: .vsts.template.windows.yml
parameters:
componentDetection: 'true'
testLogTitle: 'Windows-x64'
# Package .NET Core Windows dependency (VC++ Redistributable)
- template: .azure-pipelines/package-vcredist.yml
parameters:
layoutRoot: '_layout/win-x64'
flavor: 'x64'
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Create agent package zip
- script: dev.cmd package Release
workingDirectory: src
displayName: Package Release
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Upload agent package zip as build artifact
- task: PublishBuildArtifacts@1
displayName: Publish Artifact (Windows x64)
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
inputs:
pathToPublish: _package
artifactName: agent
artifactType: container
################################################################################
- job: build_windows_x86_agent
################################################################################
displayName: Windows Agent (x86)
pool:
name: buildDevs
demands: 'Agent.OSArchitecture -equals X86'
steps:
# Steps template for windows platform
- template: .vsts.template.windows.yml
parameters:
testLogTitle: 'Windows-x86'
# Package .NET Core Windows dependency (VC++ Redistributable)
- template: .azure-pipelines/package-vcredist.yml
parameters:
layoutRoot: '_layout/win-x86'
flavor: 'x86'
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Create agent package zip
- script: dev.cmd package Release
workingDirectory: src
displayName: Package Release
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Upload agent package zip as build artifact
- task: PublishBuildArtifacts@1
displayName: Publish Artifact (Windows x86)
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
inputs:
pathToPublish: _package
artifactName: agent
artifactType: container
################################################################################
- job: build_linux_x64_agent
################################################################################
displayName: Linux Agent (x64)
pool:
vmImage: ubuntu-16.04
steps:
# Steps template for non-windows platform
- template: .vsts.template.nonwindows.yml
parameters:
componentDetection: 'true'
testLogTitle: 'Linux-x64'
# Create agent package zip
- script: ./dev.sh package Release
workingDirectory: src
displayName: Package Release
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Upload agent package zip as build artifact
- task: PublishBuildArtifacts@1
displayName: Publish Artifact (Linux x64)
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
inputs:
pathToPublish: _package
artifactName: agent
artifactType: container
################################################################################
- job: build_linux_arm_agent
################################################################################
displayName: Linux Agent (ARM)
pool:
name: buildDevs
demands: 'Agent.OSArchitecture -equals ARM'
container: dotnetcore_arm
steps:
# Steps template for non-windows platform
- template: .vsts.template.nonwindows.yml
parameters:
testLogTitle: 'Linux-ARM'
# Create agent package zip
- script: ./dev.sh package Release
workingDirectory: src
displayName: Package Release
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Upload agent package zip as build artifact
- task: PublishBuildArtifacts@1
displayName: Publish Artifact (Linux ARM)
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
inputs:
pathToPublish: _package
artifactName: agent
artifactType: container
################################################################################
- job: build_rhel6_x64_agent
################################################################################
displayName: RHEL6 Agent (x64)
pool:
vmImage: ubuntu-16.04
container: dotnetcore_centos6
steps:
# Steps template for non-windows platform
- template: .vsts.template.nonwindows.yml
parameters:
testLogTitle: 'RHEL-x64'
# Create agent package zip
- script: ./dev.sh package Release
workingDirectory: src
displayName: Package Release
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Upload agent package zip as build artifact
- task: PublishBuildArtifacts@1
displayName: Publish Artifact (RHEL6 x64)
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
inputs:
pathToPublish: _package
artifactName: agent
artifactType: container
################################################################################
- job: build_osx_agent
################################################################################
displayName: macOS Agent (x64)
pool:
vmImage: macOS-10.13
steps:
# Steps template for non-windows platform
- template: .vsts.template.nonwindows.yml
parameters:
componentDetection: 'true'
testLogTitle: 'macOS-x64'
# Create agent package zip
- script: ./dev.sh package Release
workingDirectory: src
displayName: Package Release
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
# Upload agent package zip as build artifact
- task: PublishBuildArtifacts@1
displayName: Publish Artifact (OSX)
condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
inputs:
pathToPublish: _package
artifactName: agent
artifactType: container