|
| 1 | +# CI and PR triggers |
| 2 | +trigger: |
| 3 | +- master |
| 4 | +- dev16.1 |
| 5 | +- feature/* |
| 6 | +- release/* |
| 7 | +pr: |
| 8 | +- master |
| 9 | +- dev16.1 |
| 10 | +- feature/* |
| 11 | +- release/* |
| 12 | + |
| 13 | +variables: |
| 14 | + - name: _TeamName |
| 15 | + value: FSharp |
| 16 | + - name: _BuildConfig |
| 17 | + value: Release |
| 18 | + - name: _PublishUsingPipelines |
| 19 | + value: true |
| 20 | + - name: _DotNetArtifactsCategory |
| 21 | + value: .NETCore |
| 22 | + - name: VisualStudioDropName |
| 23 | + value: Products/$(System.TeamProject)/$(Build.Repository.Name)/$(Build.SourceBranchName)/$(Build.BuildNumber) |
| 24 | + |
| 25 | +# Variables defined in yml cannot be overridden at queue time; instead overridable variables must be defined in the web UI. |
| 26 | +# Commenting out until something like this is supported: https://github.com/Microsoft/azure-pipelines-yaml/pull/129 |
| 27 | +#variables: |
| 28 | +#- name: SkipTests |
| 29 | +# defaultValue: false |
| 30 | + |
| 31 | +jobs: |
| 32 | + |
| 33 | +#---------------------------------------------------------------------------------------------------------------------# |
| 34 | +# Signed build # |
| 35 | +#---------------------------------------------------------------------------------------------------------------------# |
| 36 | +- ${{ if and(ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: |
| 37 | + - template: /eng/common/templates/jobs/jobs.yml |
| 38 | + parameters: |
| 39 | + enableMicrobuild: true |
| 40 | + enablePublishBuildArtifacts: true |
| 41 | + enablePublishTestResults: false |
| 42 | + enablePublishBuildAssets: true |
| 43 | + enablePublishUsingPipelines: $(_PublishUsingPipelines) |
| 44 | + enableTelemetry: true |
| 45 | + helixRepo: dotnet/fsharp |
| 46 | + jobs: |
| 47 | + - job: Full_Signed |
| 48 | + pool: |
| 49 | + name: NetCoreInternal-Int-Pool |
| 50 | + queue: buildpool.windows.10.amd64.vs2019 |
| 51 | + timeoutInMinutes: 300 |
| 52 | + variables: |
| 53 | + - group: DotNet-Blob-Feed |
| 54 | + - group: DotNet-Symbol-Server-Pats |
| 55 | + - name: _SignType |
| 56 | + value: Real |
| 57 | + - name: _DotNetPublishToBlobFeed |
| 58 | + value: true |
| 59 | + steps: |
| 60 | + - checkout: self |
| 61 | + clean: true |
| 62 | + - script: eng\CIBuild.cmd |
| 63 | + -configuration $(_BuildConfig) |
| 64 | + -prepareMachine |
| 65 | + -testAll |
| 66 | + -officialSkipTests $(SkipTests) |
| 67 | + /p:SignType=$(_SignType) |
| 68 | + /p:DotNetSignType=$(_SignType) |
| 69 | + /p:MicroBuild_SigningEnabled=true |
| 70 | + /p:OverridePackageSource=https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json |
| 71 | + /p:TeamName=$(_TeamName) |
| 72 | + /p:DotNetPublishBlobFeedKey=$(dotnetfeed-storage-access-key-1) |
| 73 | + /p:DotNetPublishBlobFeedUrl=https://dotnetfeed.blob.core.windows.net/dotnet-core/index.json |
| 74 | + /p:DotNetPublishToBlobFeed=true |
| 75 | + /p:DotNetPublishUsingPipelines=$(_PublishUsingPipelines) |
| 76 | + /p:DotNetArtifactsCategory=$(_DotNetArtifactsCategory) |
| 77 | + /p:DotNetSymbolServerTokenMsdl=$(microsoft-symbol-server-pat) |
| 78 | + /p:DotNetSymbolServerTokenSymWeb=$(symweb-symbol-server-pat) |
| 79 | + /p:OfficialBuildId=$(BUILD.BUILDNUMBER) |
| 80 | + /p:PublishToSymbolServer=true |
| 81 | + /p:VisualStudioDropName=$(VisualStudioDropName) |
| 82 | + - task: PublishTestResults@2 |
| 83 | + displayName: Publish Test Results |
| 84 | + inputs: |
| 85 | + testResultsFormat: 'NUnit' |
| 86 | + testResultsFiles: '*.xml' |
| 87 | + searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' |
| 88 | + continueOnError: true |
| 89 | + condition: ne(variables['SkipTests'], 'true') |
| 90 | + - task: PublishBuildArtifacts@1 |
| 91 | + displayName: Publish Test Logs |
| 92 | + inputs: |
| 93 | + PathtoPublish: '$(Build.SourcesDirectory)\artifacts\TestResults\$(_BuildConfig)' |
| 94 | + ArtifactName: 'Test Logs' |
| 95 | + publishLocation: Container |
| 96 | + continueOnError: true |
| 97 | + condition: ne(variables['SkipTests'], 'true') |
| 98 | + - task: PublishBuildArtifacts@1 |
| 99 | + displayName: Publish Artifact Packages |
| 100 | + inputs: |
| 101 | + PathtoPublish: '$(Build.SourcesDirectory)\artifacts\packages\$(_BuildConfig)' |
| 102 | + ArtifactName: 'Packages' |
| 103 | + condition: succeeded() |
| 104 | + - task: PublishBuildArtifacts@1 |
| 105 | + displayName: Publish Artifact VSSetup |
| 106 | + inputs: |
| 107 | + PathtoPublish: '$(Build.SourcesDirectory)\artifacts\VSSetup\$(_BuildConfig)\Insertion' |
| 108 | + ArtifactName: 'VSSetup' |
| 109 | + condition: succeeded() |
| 110 | + - task: PublishBuildArtifacts@1 |
| 111 | + displayName: Publish Artifact Nightly |
| 112 | + inputs: |
| 113 | + PathtoPublish: '$(Build.SourcesDirectory)\artifacts\VSSetup\$(_BuildConfig)\VisualFSharpFull.vsix' |
| 114 | + ArtifactName: 'Nightly' |
| 115 | + condition: succeeded() |
| 116 | + |
| 117 | +#---------------------------------------------------------------------------------------------------------------------# |
| 118 | +# PR builds # |
| 119 | +#---------------------------------------------------------------------------------------------------------------------# |
| 120 | +- ${{ if eq(variables['System.TeamProject'], 'public') }}: |
| 121 | + - template: /eng/common/templates/jobs/jobs.yml |
| 122 | + parameters: |
| 123 | + enableMicrobuild: true |
| 124 | + enablePublishBuildArtifacts: true |
| 125 | + enablePublishTestResults: false |
| 126 | + enablePublishBuildAssets: true |
| 127 | + enablePublishUsingPipelines: $(_PublishUsingPipelines) |
| 128 | + enableTelemetry: true |
| 129 | + helixRepo: dotnet/fsharp |
| 130 | + jobs: |
| 131 | + |
| 132 | + # Windows |
| 133 | + - job: Windows |
| 134 | + pool: |
| 135 | + vmImage: windows-2019 |
| 136 | + timeoutInMinutes: 120 |
| 137 | + strategy: |
| 138 | + maxParallel: 4 |
| 139 | + matrix: |
| 140 | + desktop_release: |
| 141 | + _configuration: Release |
| 142 | + _testKind: testDesktop |
| 143 | + coreclr_release: |
| 144 | + _configuration: Release |
| 145 | + _testKind: testCoreclr |
| 146 | + fsharpqa_release: |
| 147 | + _configuration: Release |
| 148 | + _testKind: testFSharpQA |
| 149 | + vs_release: |
| 150 | + _configuration: Release |
| 151 | + _testKind: testVs |
| 152 | + steps: |
| 153 | + - checkout: self |
| 154 | + clean: true |
| 155 | + - script: eng\CIBuild.cmd -configuration $(_configuration) -$(_testKind) |
| 156 | + displayName: Build / Test |
| 157 | + - task: PublishTestResults@2 |
| 158 | + displayName: Publish Test Results |
| 159 | + inputs: |
| 160 | + testResultsFormat: 'NUnit' |
| 161 | + testResultsFiles: '*.xml' |
| 162 | + searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_configuration)' |
| 163 | + continueOnError: true |
| 164 | + condition: ne(variables['_testKind'], 'testFSharpQA') |
| 165 | + - task: PublishBuildArtifacts@1 |
| 166 | + displayName: Publish Test Logs |
| 167 | + inputs: |
| 168 | + PathtoPublish: '$(Build.SourcesDirectory)\artifacts\TestResults\$(_configuration)' |
| 169 | + ArtifactName: 'Windows $(_configuration) $(_testKind) test logs' |
| 170 | + publishLocation: Container |
| 171 | + continueOnError: true |
| 172 | + condition: eq(variables['_testKind'], 'testFSharpQA') |
| 173 | + |
| 174 | + # Linux |
| 175 | + - job: Linux |
| 176 | + pool: |
| 177 | + vmImage: ubuntu-16.04 |
| 178 | + variables: |
| 179 | + - name: _SignType |
| 180 | + value: Test |
| 181 | + steps: |
| 182 | + - checkout: self |
| 183 | + clean: true |
| 184 | + - script: ./eng/cibuild.sh --configuration $(_BuildConfig) --testcoreclr |
| 185 | + displayName: Build / Test |
| 186 | + - task: PublishTestResults@2 |
| 187 | + displayName: Publish Test Results |
| 188 | + inputs: |
| 189 | + testResultsFormat: 'NUnit' |
| 190 | + testResultsFiles: '*.xml' |
| 191 | + searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' |
| 192 | + continueOnError: true |
| 193 | + condition: always() |
| 194 | + |
| 195 | + # MacOS |
| 196 | + - job: MacOS |
| 197 | + pool: |
| 198 | + vmImage: macOS-10.13 |
| 199 | + variables: |
| 200 | + - name: _SignType |
| 201 | + value: Test |
| 202 | + steps: |
| 203 | + - checkout: self |
| 204 | + clean: true |
| 205 | + - script: ./eng/cibuild.sh --configuration $(_BuildConfig) --testcoreclr |
| 206 | + displayName: Build / Test |
| 207 | + - task: PublishTestResults@2 |
| 208 | + displayName: Publish Test Results |
| 209 | + inputs: |
| 210 | + testResultsFormat: 'NUnit' |
| 211 | + testResultsFiles: '*.xml' |
| 212 | + searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' |
| 213 | + continueOnError: true |
| 214 | + condition: always() |
| 215 | + |
| 216 | + # Source Build Linux |
| 217 | + - job: SourceBuild_Linux |
| 218 | + pool: |
| 219 | + vmImage: ubuntu-16.04 |
| 220 | + steps: |
| 221 | + - checkout: self |
| 222 | + clean: true |
| 223 | + - script: ./eng/cibuild.sh --configuration Release /p:DotNetBuildFromSource=true /p:FSharpSourceBuild=true |
| 224 | + displayName: Build |
| 225 | + |
| 226 | + # Source Build Windows |
| 227 | + - job: SourceBuild_Windows |
| 228 | + pool: |
| 229 | + vmImage: windows-2019 |
| 230 | + steps: |
| 231 | + - checkout: self |
| 232 | + clean: true |
| 233 | + - script: eng\CIBuild.cmd -configuration Release -noSign /p:DotNetBuildFromSource=true /p:FSharpSourceBuild=true |
| 234 | + displayName: Build |
| 235 | + |
| 236 | + # Up-to-date |
| 237 | + - job: UpToDate_Windows |
| 238 | + pool: |
| 239 | + vmImage: windows-2019 |
| 240 | + steps: |
| 241 | + - checkout: self |
| 242 | + clean: true |
| 243 | + - task: PowerShell@2 |
| 244 | + displayName: Run up-to-date build check |
| 245 | + inputs: |
| 246 | + filePath: eng\tests\UpToDate.ps1 |
| 247 | + arguments: -configuration $(_BuildConfig) -ci -binaryLog |
| 248 | + |
| 249 | +#---------------------------------------------------------------------------------------------------------------------# |
| 250 | +# FCS builds # |
| 251 | +#---------------------------------------------------------------------------------------------------------------------# |
| 252 | + |
| 253 | +- ${{ if eq(variables['System.TeamProject'], 'public') }}: |
| 254 | + - template: /eng/common/templates/jobs/jobs.yml |
| 255 | + parameters: |
| 256 | + enableMicrobuild: true |
| 257 | + enablePublishTestResults: false |
| 258 | + enablePublishBuildAssets: true |
| 259 | + enablePublishUsingPipelines: false |
| 260 | + enableTelemetry: true |
| 261 | + helixRepo: dotnet/fsharp |
| 262 | + jobs: |
| 263 | + |
| 264 | + - job: Windows_FCS |
| 265 | + pool: |
| 266 | + vmImage: windows-2019 |
| 267 | + variables: |
| 268 | + - name: _SignType |
| 269 | + value: Test |
| 270 | + steps: |
| 271 | + - checkout: self |
| 272 | + clean: true |
| 273 | + - script: fcs\build.cmd TestAndNuget |
| 274 | + displayName: Build / Test |
| 275 | + - task: PublishTestResults@2 |
| 276 | + displayName: Publish Test Results |
| 277 | + inputs: |
| 278 | + testResultsFormat: 'NUnit' |
| 279 | + testResultsFiles: '*.xml' |
| 280 | + searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/Release' |
| 281 | + continueOnError: true |
| 282 | + condition: always() |
| 283 | + |
| 284 | + - job: Linux_FCS |
| 285 | + pool: |
| 286 | + vmImage: ubuntu-16.04 |
| 287 | + variables: |
| 288 | + - name: _SignType |
| 289 | + value: Test |
| 290 | + steps: |
| 291 | + - checkout: self |
| 292 | + clean: true |
| 293 | + - script: ./fcs/build.sh Build |
| 294 | + displayName: Build |
| 295 | + |
| 296 | + - job: MacOS_FCS |
| 297 | + pool: |
| 298 | + vmImage: macOS-10.13 |
| 299 | + variables: |
| 300 | + - name: _SignType |
| 301 | + value: Test |
| 302 | + steps: |
| 303 | + - checkout: self |
| 304 | + clean: true |
| 305 | + - script: ./fcs/build.sh Build |
| 306 | + displayName: Build |
0 commit comments