-
Notifications
You must be signed in to change notification settings - Fork 0
/
build-selfservice.yml
62 lines (55 loc) · 1.59 KB
/
build-selfservice.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
trigger:
- master
pool:
vmImage: "ubuntu-20.04"
variables:
BuildConfiguration: 'Release'
AzureSubscriptionEndpoint: 'visual-studio-enterprise'
WebAppName: tmobileplan
EnvironmentName: tmobileplan
stages:
- stage: 'build'
displayName: 'build'
jobs:
- job:
displayName: 'build'
pool:
vmImage: 'vs2017-win2016'
steps:
- task: PowerShell@2
inputs:
targetType: inline
script: pwd ; get-childitem -Recurse
- task: DotNetCoreCLI@2
displayName: 'build'
inputs:
command: publish
projects: 'src\web\SelfService\Server\SelfService.Server.csproj'
publishWebProjects: true
arguments: '--configuration $(BuildConfiguration) --output $(Build.ArtifactStagingDirectory)'
zipAfterPublish: true
- task: PublishBuildArtifacts@1
displayName: 'Artifacts'
inputs:
pathtoPublish: '$(Build.ArtifactStagingDirectory)'
artifactName: 'drop'
- stage: 'deploy'
displayName: 'deploy'
jobs:
- deployment:
pool:
vmImage: 'vs2017-win2016'
environment: '$(EnvironmentName)'
strategy:
runOnce:
deploy:
steps:
- task: AzureRMWebAppDeployment@4
displayName: Azure App service apiVersion
inputs:
appType: webApp
connectedServiceName: $(AzureSubscriptionEndpoint)
WebAppName: $(WebAppName)
Package: $(System.WorkFolder)/**/Server.zip
UseWebDeploy: true
DeploymentType: webDeploy