-
Notifications
You must be signed in to change notification settings - Fork 52
/
azure-pipelines.yml
52 lines (43 loc) · 1.46 KB
/
azure-pipelines.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
# ASP.NET Core
# Build and test ASP.NET Core projects targeting .NET Core.
# Add steps that run tests, create a NuGet package, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/dotnet-core
trigger:
- main
pool:
vmImage: 'windows-latest' # publish needs to be win-x86
variables:
buildConfiguration: 'Release'
steps:
- task: UseDotNet@2
displayName: 'Installing .NET Core SDK 6.0'
inputs:
packageType: 'sdk'
version: '6.0.x'
- task: DotNetCoreCLI@2
displayName: 'Restore packages'
inputs:
command: 'restore'
projects: 'BlazorChatSample.sln'
feedsToUse: 'select'
- task: DotNetCoreCLI@2
displayName: 'Build'
inputs:
command: 'build'
projects: 'BlazorChatSample.sln'
arguments: '--configuration $(buildConfiguration) --no-restore'
- task: DotNetCoreCLI@2
displayName: 'publish'
inputs:
command: 'publish'
arguments: '--configuration $(buildConfiguration) --output $(Build.ArtifactStagingDirectory) --self-contained true --runtime win-x86 --no-build'
- task: DotNetCoreCLI@2
displayName: 'publish'
inputs:
command: 'publish'
publishWebProjects: false
projects: 'BlazorChatSample.Server\BlazorChatSample.Server.csproj'
arguments: '--configuration $(BuildConfiguration) --output "$(build.artifactstagingdirectory)" --framework net6.0 --self-contained true --runtime win-x86'
modifyOutputPath: false
- task: PublishBuildArtifacts@1
displayName: 'Publishing Build Artifacts...'