1
1
phases :
2
2
3
3
# ###############################################################################
4
- - phase : build_windows_agent
4
+ - phase : build_windows_x64_agent
5
5
# ###############################################################################
6
- displayName : Windows Agent
6
+ displayName : Windows Agent (x64)
7
7
queue :
8
8
name : Hosted VS2017
9
- condition : eq(false, variables.skip_windows )
9
+ condition : eq(false, variables.skip_windows_x64 )
10
10
steps :
11
11
12
12
# Steps template for windows platform
13
13
- template : .vsts.template.windows.yml
14
-
14
+
15
15
# Package dotnet core windows dependency (VC++ Redistributable)
16
16
- powershell : |
17
17
Write-Host "Downloading 'VC++ Redistributable' package."
18
18
$outDir = Join-Path -Path $env:TMP -ChildPath ([Guid]::NewGuid())
19
19
New-Item -Path $outDir -ItemType directory
20
20
$outFile = Join-Path -Path $outDir -ChildPath "ucrt.zip"
21
- Invoke-WebRequest -Uri https://vstsagenttools.blob.core.windows.net/tools/ucrt/ucrt .zip -OutFile $outFile
21
+ Invoke-WebRequest -Uri https://vstsagenttools.blob.core.windows.net/tools/ucrt/ucrt_x64 .zip -OutFile $outFile
22
22
Write-Host "Unzipping 'VC++ Redistributable' package to agent layout."
23
23
$unzipDir = Join-Path -Path $outDir -ChildPath "unzip"
24
24
Add-Type -AssemblyName System.IO.Compression.FileSystem
@@ -36,20 +36,92 @@ phases:
36
36
37
37
# Upload agent package zip as build artifact
38
38
- task : PublishBuildArtifacts@1
39
- displayName : Publish Artifact (Windows)
39
+ displayName : Publish Artifact (Windows x64)
40
+ condition : and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
41
+ inputs :
42
+ pathToPublish : _package
43
+ artifactName : agent
44
+ artifactType : container
45
+
46
+ # ###############################################################################
47
+ - phase : build_windows_x86_agent
48
+ # ###############################################################################
49
+ displayName : Windows Agent (x86)
50
+ queue :
51
+ name : buildDevs
52
+ demands : ' Agent.OSArchitecture -equals X86'
53
+ condition : eq(false, variables.skip_windows_x86)
54
+ steps :
55
+
56
+ # Steps template for windows platform
57
+ - template : .vsts.template.windows.yml
58
+
59
+ # Package dotnet core windows dependency (VC++ Redistributable)
60
+ - powershell : |
61
+ Write-Host "Downloading 'VC++ Redistributable' package."
62
+ $outDir = Join-Path -Path $env:TMP -ChildPath ([Guid]::NewGuid())
63
+ New-Item -Path $outDir -ItemType directory
64
+ $outFile = Join-Path -Path $outDir -ChildPath "ucrt.zip"
65
+ Invoke-WebRequest -Uri https://vstsagenttools.blob.core.windows.net/tools/ucrt/ucrt_x86.zip -OutFile $outFile
66
+ Write-Host "Unzipping 'VC++ Redistributable' package to agent layout."
67
+ $unzipDir = Join-Path -Path $outDir -ChildPath "unzip"
68
+ Add-Type -AssemblyName System.IO.Compression.FileSystem
69
+ [System.IO.Compression.ZipFile]::ExtractToDirectory($outFile, $unzipDir)
70
+ $agentLayoutBin = Join-Path -Path $(Build.SourcesDirectory) -ChildPath "_layout\bin"
71
+ Copy-Item -Path $unzipDir -Destination $agentLayoutBin -Force
72
+ displayName: Package UCRT
73
+ condition: and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
74
+
75
+ # Create agent package zip
76
+ - script : dev.cmd package Release
77
+ workingDirectory : src
78
+ displayName : Package Release
79
+ condition : and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
80
+
81
+ # Upload agent package zip as build artifact
82
+ - task : PublishBuildArtifacts@1
83
+ displayName : Publish Artifact (Windows x86)
84
+ condition : and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
85
+ inputs :
86
+ pathToPublish : _package
87
+ artifactName : agent
88
+ artifactType : container
89
+
90
+ # ###############################################################################
91
+ - phase : build_linux_x64_agent
92
+ # ###############################################################################
93
+ displayName : Linux Agent (x64)
94
+ queue :
95
+ name : Hosted Ubuntu 1604
96
+ condition : eq(false, variables.skip_linux_x64)
97
+ steps :
98
+
99
+ # Steps template for windows platform
100
+ - template : .vsts.template.nonwindows.yml
101
+
102
+ # Create agent package zip
103
+ - script : ./dev.sh package Release
104
+ workingDirectory : src
105
+ displayName : Package Release
106
+ condition : and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
107
+
108
+ # Upload agent package zip as build artifact
109
+ - task : PublishBuildArtifacts@1
110
+ displayName : Publish Artifact (Linux x64)
40
111
condition : and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
41
112
inputs :
42
113
pathToPublish : _package
43
114
artifactName : agent
44
115
artifactType : container
45
116
46
117
# ###############################################################################
47
- - phase : build_linux_agent
118
+ - phase : build_linux_arm_agent
48
119
# ###############################################################################
49
- displayName : Linux Agent
120
+ displayName : Linux Agent (ARM)
50
121
queue :
51
- name : Hosted Linux Preview
52
- condition : eq(false, variables.skip_linux)
122
+ name : buildDevs
123
+ demands : ' Agent.OSArchitecture -equals ARM'
124
+ condition : eq(false, variables.skip_linux_arm)
53
125
steps :
54
126
55
127
# Steps template for windows platform
@@ -63,7 +135,7 @@ phases:
63
135
64
136
# Upload agent package zip as build artifact
65
137
- task : PublishBuildArtifacts@1
66
- displayName : Publish Artifact (Linux)
138
+ displayName : Publish Artifact (Linux ARM )
67
139
condition : and(succeeded(), ne(variables['build.reason'], 'PullRequest'))
68
140
inputs :
69
141
pathToPublish : _package
@@ -73,7 +145,7 @@ phases:
73
145
# ###############################################################################
74
146
- phase : build_osx_agent
75
147
# ###############################################################################
76
- displayName : OSX Agent
148
+ displayName : macOS Agent (x64)
77
149
queue :
78
150
name : Hosted macOS Preview
79
151
condition : eq(false, variables.skip_macos)
0 commit comments