-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathazure-pipelines.yml
52 lines (48 loc) · 1.58 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
trigger:
- master
- main
- develop
resources:
repositories:
- repository: templates
type: git
name: Operações/template-take-blip
ref: refs/tags/v1.4.48
variables:
BuildCounter: $[counter('buildCounter',1)]
sonarQubeTags: $(Build.Repository.Name)
sonarQubeKey: $(Build.Repository.Name)
sonarQubeName: $(Build.Repository.Name)
framework: 'react'
pool:
vmImage: 'ubuntu-latest'
extends:
template: 'template-pipeline.yml@templates'
parameters:
type: 'javascript'
to: 'kubernetes'
packagename: $(Build.Repository.Name)
BuildCounter: $(BuildCounter)
nodeVersion: '18.16.0'
createZipPackage: true
buildArtifactsDir: 'build'
npmCmds:
- 'npm cache clean --force'
- 'npm install'
- 'npm run test:coverage'
- 'npm run build'
stages:
- name: staging
condition: and(or(ne(variables['build.sourceBranchName'], 'master'), ne(variables['build.sourceBranchName'], 'main')), ne(variables['Build.Reason'], 'PullRequest'))
dependsOn: build
environment: staging
ServiceConnection: 'AKS BOT BETA-STAGING-$(System.TeamProject)'
# Add Key Vaults' variable groups here
variables: []
- name: production
condition: and(or(eq(variables['build.sourceBranchName'], 'master'), eq(variables['build.sourceBranchName'], 'main')), ne(variables['Build.Reason'], 'PullRequest'))
dependsOn: staging
environment: production
# Add Key Vaults' variable groups here
variables: []
ServiceConnection: 'AKS BOT PROD-$(System.TeamProject)'