-
Notifications
You must be signed in to change notification settings - Fork 1.4k
/
spec.yaml
131 lines (122 loc) · 3.97 KB
/
spec.yaml
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
name: SonarQube
files:
- name: sonarqube.yaml
options:
- template: init_config
options:
- template: init_config/jmx
overrides:
is_jmx.required: false
is_jmx.value.example: false
- template: init_config/http
- template: instances
options:
- name: web_endpoint
description: |
The SonarQube web endpoint which should expose its API at `/api`. For example:
web_endpoint: http://<WEB_ENDPOINT>:<PORT>
NOTE: This only takes effect when `is_jmx` is set to `false` and is required for all
API metrics.
value:
type: string
- name: default_tag
description: |
The tag name to use for `components` by default.
NOTE: This only takes effect when `is_jmx` is set to `false`.
value:
type: string
example: component
- name: default_include
description: |
A list of regular expressions that decides what metrics to collect by default. For brevity,
you may elide the `sonarqube.` prefix and `.` (dot) characters are treated literally.
By default, all available metrics are collected.
NOTE: This only takes effect when `is_jmx` is set to `false`.
value:
type: array
items:
type: string
- name: default_exclude
description: |
A list of regular expressions that decides what metrics to exclude by default. For brevity,
you may elide the `sonarqube.` prefix and `.` (dot) characters are treated literally.
By default, no metrics are excluded.
NOTE: This only takes effect when `is_jmx` is set to `false`.
value:
type: array
items:
type: string
- name: components
description: |
The components for which metrics should be collected. Each object may override the default
options. For example, the following will gather all default metrics for "some-project",
and only what is included/excluded for "another-project":
components:
some-project:
another-project:
tag: project-2
include:
- issues.
- maintainability.
- security.
exclude:
- issues.(false_positive_issues|reopened_issues)
NOTE: This is required for all project checks, regardless of `is_jmx` being set to `true`
or `false.
value:
type: object
properties:
- name: tag
type: string
- name: include
type: array
items:
type: string
- name: exclude
type: array
items:
type: string
- template: instances/jmx
overrides:
host.required: false
port.required: false
user.description: |
User name to use when connecting to JMX (or HTTP if `is_jmx = false`).
password.description: |
Password to use when connecting to JMX (or HTTP if `is_jmx = false`).
- template: instances/http
overrides:
password.hidden: true
- template: logs
example:
- type: file
path: /opt/sonarqube/logs/access.log
source: sonarqube
- type: file
path: /opt/sonarqube/logs/ce.log
source: sonarqube
log_processing_rules:
- type: multi_line
name: log_start_with_date
pattern: \d{4}\.\d{2}\.\d{2}
- type: file
path: /opt/sonarqube/logs/es.log
source: sonarqube
log_processing_rules:
- type: multi_line
name: log_start_with_date
pattern: \d{4}\.\d{2}\.\d{2}
- type: file
path: /opt/sonarqube/logs/sonar.log
source: sonarqube
log_processing_rules:
- type: multi_line
name: log_start_with_date
pattern: \d{4}\.\d{2}\.\d{2}
- type: file
path: /opt/sonarqube/logs/web.log
source: sonarqube
log_processing_rules:
- type: multi_line
name: log_start_with_date
pattern: \d{4}\.\d{2}\.\d{2}