forked from phongnguyend/Practical.CleanArchitecture
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
57 lines (52 loc) · 1.34 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
trigger:
- main
resources:
- repo: self
variables:
# Agent VM image name
vmImageName: 'ubuntu-latest'
stages:
- stage: Build
displayName: Build
jobs:
- job: Build
displayName: Build ReactJs
pool:
vmImage: ubuntu-latest
steps:
- checkout: self
- task: NodeTool@0
displayName: Use Node 12.x
inputs:
versionSpec: 12.x
checkLatest: true
- task: Npm@1
displayName: npm install
inputs:
workingDir: src/UIs/reactjs
- task: Npm@1
displayName: npm audit --audit-level=high
inputs:
command: 'custom'
workingDir: 'src/UIs/reactjs'
customCommand: 'audit --audit-level=critical'
- task: Npm@1
displayName: run build
inputs:
command: custom
workingDir: src/UIs/reactjs
customCommand: run build
- task: ArchiveFiles@2
displayName: Archive
inputs:
rootFolderOrFile: 'src/UIs/reactjs/build'
includeRootFolder: false
archiveType: 'zip'
archiveFile: '$(Build.ArtifactStagingDirectory)/reactjs.$(Build.BuildId).zip'
replaceExistingArchive: true
- task: PublishPipelineArtifact@1
displayName: Publish Pipeline Artifact
inputs:
targetPath: '$(Build.ArtifactStagingDirectory)'
artifact: 'ReactJs'
publishLocation: 'pipeline'