File tree Expand file tree Collapse file tree 8 files changed +67
-1
lines changed
charts/prom-aggregation-gateway Expand file tree Collapse file tree 8 files changed +67
-1
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,12 @@ helm repo update
9393helm search repo pag -l
9494```
9595
96+ ### Helm Chart Unit Tests
97+
98+ Helm plugin [ quintush/helm-unittest] ( https://github.com/quintush/helm-unittest ) is used for unit-testing.
99+ After installing the plugin run ` helm unittest <chart_dir> ` . For Helm 3 support use ` --helm3 ` flag.
100+ More information on writing tests might be found in the plugin's project repo.
101+
96102## Contributing
97103To run the server you can run:
98104
Original file line number Diff line number Diff line change 11apiVersion : v2
22name : prom-aggregation-gateway
3- version : 0.5.4
3+ version : 0.6.0
44home : https://github.com/zapier/prom-aggregation-gateway
55maintainers :
66 - name : djeebus
Original file line number Diff line number Diff line change @@ -3,6 +3,10 @@ apiVersion: monitoring.coreos.com/v1
33kind : PodMonitor
44metadata :
55 name : {{ .Release.Name }}-metrics
6+ {{- with .Values.podMonitor.additionalLabels }}
7+ labels :
8+ {{- toYaml . | nindent 4 }}
9+ {{- end }}
610spec :
711 selector :
812 matchLabels :
Original file line number Diff line number Diff line change @@ -3,6 +3,10 @@ apiVersion: monitoring.coreos.com/v1
33kind : ServiceMonitor
44metadata :
55 name : {{ .Release.Name }}
6+ {{- with .Values.serviceMonitor.additionalLabels }}
7+ labels :
8+ {{- toYaml . | nindent 4 }}
9+ {{- end }}
610spec :
711 selector :
812 matchLabels :
Original file line number Diff line number Diff line change 1+ suite : PodMonitor tests
2+
3+ templates : [podmonitor.yaml]
4+
5+ tests :
6+ - it : empty podmonitor labels by default
7+ asserts :
8+ - isEmpty :
9+ path : metadata.labels
10+ - it : can render podmonitor labels
11+ set :
12+ podMonitor :
13+ additionalLabels :
14+ hello : world
15+ goodbye : moon
16+ asserts :
17+ - equal :
18+ path : metadata.labels
19+ value :
20+ hello : world
21+ goodbye : moon
Original file line number Diff line number Diff line change 1+ suite : ServiceMonitor tests
2+
3+ templates : [servicemonitor.yaml]
4+
5+ tests :
6+ - it : empty servicemonitor labels by default
7+ asserts :
8+ - isEmpty :
9+ path : metadata.labels
10+ - it : can render servicemonitor labels
11+ set :
12+ serviceMonitor :
13+ additionalLabels :
14+ hello : world
15+ goodbye : moon
16+ asserts :
17+ - equal :
18+ path : metadata.labels
19+ value :
20+ hello : world
21+ goodbye : moon
Original file line number Diff line number Diff line change 9191 "properties" : {
9292 "create" : {
9393 "type" : " boolean"
94+ },
95+ "additionalLabels" : {
96+ "type" : " object" ,
97+ "additionalProperties" : true
9498 }
9599 }
96100 },
100104 "properties" : {
101105 "create" : {
102106 "type" : " boolean"
107+ },
108+ "additionalLabels" : {
109+ "type" : " object" ,
110+ "additionalProperties" : true
103111 }
104112 }
105113 }
Original file line number Diff line number Diff line change @@ -19,6 +19,7 @@ controller:
1919
2020podMonitor :
2121 create : true
22+ additionalLabels : {}
2223
2324service :
2425 create : true
@@ -29,3 +30,4 @@ service:
2930
3031serviceMonitor :
3132 create : true
33+ additionalLabels : {}
You can’t perform that action at this time.
0 commit comments