diff --git a/common/values.service-monitor.yaml b/common/values.service-monitor.yaml new file mode 100644 index 0000000..e38654f --- /dev/null +++ b/common/values.service-monitor.yaml @@ -0,0 +1,16 @@ +--- +service-monitor: + templates: + - | + {{ range .Values.service-monitor.resources }} + apiVersion: monitoring.coreos.com/v1 + kind: ServiceMonitor + metadata: + name: {{ .name }} + spec: + selector: + matchLabels: + exporter: {{ .label.exporter }} + endpoints: + - port: {{ .endpoints.port }} + {{ end }} diff --git a/releases.yaml b/releases.yaml index 2359f94..1886d85 100644 --- a/releases.yaml +++ b/releases.yaml @@ -43,6 +43,13 @@ templates: - chart: bedag/raw version: 2.0.0 alias: istio + service-monitor: + dependencies: + - chart: bedag/raw + version: 2.0.0 + alias: service-monitor + values: + - '{{ requiredEnv "PWD" }}/common/values.service-monitor.yaml' namespace: dependencies: - chart: bedag/raw @@ -160,6 +167,7 @@ templates: version: 4.6.0 inherit: - template: default-env-values + - template: service-monitor gitea: &gitea name: gitea