-
Notifications
You must be signed in to change notification settings - Fork 411
/
azure-pipelines.yml
57 lines (47 loc) · 1.35 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
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- master
pool:
vmImage: 'ubuntu-latest'
variables:
YARN_CACHE_FOLDER: $(Pipeline.Workspace)/.yarn
CURRENT_BRANCH_NAME: $(Build.SourceBranch)
steps:
- task: Cache@2
inputs:
key: 'yarn | "$(Agent.OS)" | yarn.lock'
restoreKeys: |
yarn | "$(Agent.OS)"
yarn
path: $(YARN_CACHE_FOLDER)
displayName: Cache Yarn packages
- script: yarn --frozen-lockfile
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
curl -o- -L https://yarnpkg.com/install.sh | bash
export PATH="$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:$PATH"
displayName: 'Install yarn'
- script: |
apt-get update
apt-get install software-properties-common -y
apt-get update
apt-get install jq -y
sudo ln -s bash /bin/sh.bash
sudo mv /bin/sh.bash /bin/sh
apt-get update
yarn global add npx
sh ./scripts/setup.sh
sudo ln -s dash /bin/sh.dash
sudo mv /bin/sh.dash /bin/sh
displayName: 'Build Micro-Services'
- task: PublishPipelineArtifact@1
inputs:
targetPath: '$(Pipeline.Workspace)'
artifact: 'UltimateBackend'
publishLocation: 'pipeline'