2727# A map of custom variables
2828# matrix: { string: { string: string } }
2929# A map of matrix configurations and variables. https://docs.microsoft.com/en-us/vsts/pipelines/yaml-schema?view=vsts#matrix
30- # demands: string | [ string ]
31- # A list of agent demands. https://docs.microsoft.com/en-us/vsts/pipelines/yaml-schema?view=vsts#demands
3230# dependsOn: string | [ string ]
3331# For fan-out/fan-in. https://docs.microsoft.com/en-us/vsts/pipelines/yaml-schema?view=vsts#phase
3432# codeSign: boolean
@@ -45,7 +43,6 @@ parameters:
4543 poolName : ' '
4644 buildArgs : ' '
4745 configuration : ' Release'
48- demands : []
4946 beforeBuild : []
5047 afterBuild : []
5148 codeSign : false
7168 maxParallel : 8
7269 matrix : ${{ parameters.matrix }}
7370 # Map friendly OS names to the right queue
71+ # See https://github.com/dotnet/arcade/blob/master/Documentation/ChoosingAMachinePool.md
7472 pool :
7573 ${{ if ne(parameters.poolName, '') }} :
7674 name : ${{ parameters.poolName }}
@@ -81,24 +79,25 @@ jobs:
8179 name : Hosted Ubuntu 1604
8280 vmImage : ubuntu-16.04
8381 ${{ if and(eq(parameters.poolName, ''), eq(parameters.agentOs, 'Windows')) }} :
84- ${{ if ne(parameters.codeSign, 'true') }} :
85- name : Hosted VS2017
86- vmImage : vs2017-win2016
87- ${{ if eq(parameters.codeSign, 'true') }} :
88- name : DotNetCore-Windows
82+ ${{ if eq(variables['System.TeamProject'], 'internal') }} :
83+ name : dotnet-internal-temp
84+ ${{ if ne(variables['System.TeamProject'], 'internal') }} :
85+ name : dotnet-external-temp
8986 variables :
9087 AgentOsName : ${{ parameters.agentOs }}
9188 ASPNETCORE_TEST_LOG_MAXPATH : " 200" # Keep test log file name length low enough for artifact zipping
92- DOTNET_HOME : $(Agent.WorkFolder)/.dotnet
89+ DOTNET_HOME : $(Agent.BuildDirectory)/.dotnet
90+ BuildScript : ${{ parameters.buildScript }}
9391 BuildScriptArgs : ${{ parameters.buildArgs }}
9492 BuildConfiguration : ${{ parameters.configuration }}
9593 BuildDirectory : ${{ parameters.buildDirectory }}
96- VSTS_OVERWRITE_TEMP : false # Workaround for https://github.com/dotnet/core-eng/issues/2812
97- ${{ if eq(parameters.codeSign, 'true') }} :
94+ ${{ if eq(parameters.agentOs, 'Windows') }} :
95+ JAVA_HOME : $(Agent.BuildDirectory)\.tools\jdk
96+ ${{ if or(ne(parameters.codeSign, 'true'), ne(variables['System.TeamProject'], 'internal')) }} :
97+ _SignType :
98+ ${{ if and(eq(parameters.codeSign, 'true'), eq(variables['System.TeamProject'], 'internal')) }} :
9899 TeamName : AspNetCore
99100 _SignType : real
100- ${{ if ne(parameters.codeSign, 'true') }} :
101- _SignType :
102101 ${{ insert }} : ${{ parameters.variables }}
103102 steps :
104103 - checkout : self
@@ -107,13 +106,17 @@ jobs:
107106 displayName : Install Node 10.x
108107 inputs :
109108 versionSpec : 10.x
110- - ${{ if and(eq(parameters.agentOs, 'Windows'), eq(parameters.codeSign, 'true')) }} :
109+ - ${{ if eq(parameters.agentOs, 'Windows') }} :
110+ - powershell : ./eng/scripts/InstallJdk.ps1 '11.0.1'
111+ displayName : Install JDK 11
112+ - ${{ if and(eq(variables['System.TeamProject'], 'internal'), eq(parameters.agentOs, 'Windows'), eq(parameters.codeSign, 'true')) }} :
111113 - task : MicroBuildSigningPlugin@1
112114 displayName : Install MicroBuild Signing plugin
113115 condition : and(succeeded(), in(variables['_SignType'], 'test', 'real'))
114116 inputs :
115117 signType : $(_SignType)
116118 zipSources : false
119+ feedSource : https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json
117120 - ${{ parameters.beforeBuild }}
118121 - ${{ if eq(parameters.agentOs, 'Windows') }} :
119122 - script : .\$(BuildDirectory)\build.cmd -ci /p:SignType=$(_SignType) /p:Configuration=$(BuildConfiguration) $(BuildScriptArgs)
@@ -124,6 +127,7 @@ jobs:
124127 - task : PublishTestResults@2
125128 displayName : Publish test results
126129 condition : always()
130+ continueOnError : true
127131 inputs :
128132 testRunTitle : $(AgentOsName)-$(BuildConfiguration)
129133 testRunner : vstest
@@ -133,6 +137,7 @@ jobs:
133137 - task : PublishBuildArtifacts@1
134138 displayName : Upload artifacts
135139 condition : eq(variables['system.pullrequest.isfork'], false)
140+ continueOnError : true
136141 inputs :
137142 ${{ if eq(parameters.buildDirectory, '') }} :
138143 pathtoPublish : ${{ parameters.artifacts.path }}
@@ -145,7 +150,7 @@ jobs:
145150 artifactType : Container
146151 parallel : true
147152 - ${{ parameters.afterBuild }}
148- - ${{ if and(eq(parameters.agentOs , 'Windows '), eq(parameters.codeSign , 'true ')) }} :
153+ - ${{ if and(eq(variables['System.TeamProject'] , 'internal '), eq(parameters.agentOs , 'Windows ')) }} :
149154 - task : MicroBuildCleanup@1
150155 displayName : Cleanup MicroBuild tasks
151156 condition : always()
0 commit comments