-
Notifications
You must be signed in to change notification settings - Fork 5
/
bitbucket-pipelines.yml
51 lines (51 loc) · 1.69 KB
/
bitbucket-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
image: node:11.13.0
clone:
depth: full
options:
docker: true
size: 2x
pipelines:
branches:
'{master}':
- step:
name: SonarQube analysis
script:
- pipe: sonarsource/sonarqube-scan:1.0.0
variables:
SONAR_HOST_URL: ${SONAR_HOST_URL} # Get the value from the repository/workspace variable.
SONAR_TOKEN: ${SONAR_TOKEN} # Get the value from the repository/workspace variable. You shouldn't set secret in clear text here.
services:
- docker
size: 2x
- step:
name: Check Quality Gate on SonarQube
max-time: 5 # value you should use depends on the analysis time for your project
script:
- pipe: sonarsource/sonarqube-quality-gate:1.0.0
variables:
SONAR_TOKEN: ${SONAR_TOKEN}
pull-requests:
'**':
- step:
name: SonarQube PR analysis
script:
- pipe: sonarsource/sonarqube-scan:1.0.0
variables:
SONAR_HOST_URL: ${SONAR_HOST_URL} # Get the value from the repository/workspace variable.
SONAR_TOKEN: ${SONAR_TOKEN} # Get the value from the repository/workspace variable. You shouldn't set secret in clear text here.
services:
- docker
size: 2x
- step:
name: Check Quality Gate on SonarQube
max-time: 5 # value you should use depends on the analysis time for your project
script:
- pipe: sonarsource/sonarqube-quality-gate:1.0.0
variables:
SONAR_TOKEN: ${SONAR_TOKEN}
definitions:
services:
docker:
memory: 4096
caches:
sonar: ~/.sonar