-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
58 lines (49 loc) · 1.27 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
53
54
55
56
57
58
name: Opdex-Node
trigger:
- main
resources:
- repo: self
pool:
vmImage: ubuntu-latest
variables:
ARTIFACT_NAME: 'opdex-node'
stages:
- stage: CI
displayName: 'Continuous Integration'
jobs:
- job: Build
displayName: Build and Publish
variables:
SOLUTION: 'OpdexFullNode.sln'
BUILD_CONFIGURATION: 'Release'
IMAGE_REPOSITORY: 'opdex-node'
DOCKERFILE_PATH: 'src/Opdex.Cirrus/Dockerfile'
TAG: '$(Build.SourceVersion)'
steps:
- task: DotNetCoreCLI@2
inputs:
command: 'restore'
projects: $(SOLUTION)
displayName: Restore
- task: DotNetCoreCLI@2
inputs:
command: 'build'
projects: $(SOLUTION)
arguments: '--configuration $(BUILD_CONFIGURATION) --no-restore'
displayName: 'Build'
- task: DotNetCoreCLI@2
inputs:
command: 'publish'
projects: $(SOLUTION)
publishWebProjects: False
arguments: '--configuration $(BUILD_CONFIGURATION) --no-build'
zipAfterPublish: False
displayName: Publish
- task: Docker@2
inputs:
containerRegistry: 'acr-opdex'
repository: '$(IMAGE_REPOSITORY)'
command: 'buildAndPush'
Dockerfile: '$(DOCKERFILE_PATH)'
tags: '$(TAG)'
displayName: Docker