-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(charts): hermes monitoring and prometheus rules (#1564)
## Summary Fixes hermes related monitoring service with Prometheus scraping and adds prometheus rules template for alerts. ## Background hermes monitoring service is misconfigured and alerts are yet to be implemented. ## Changes adds `serviceMonitor` and `prometheusRule` templates enabling data scraping and alerts with prometheus. also fixes current service porting and default image and labels. ## Testing against dusk-10, locally ## Metrics enables `hermes-relayer` metrics scraping
- Loading branch information
1 parent
b54ccb9
commit 8e10279
Showing
8 changed files
with
102 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{{- if .Values.alerting.enabled -}} | ||
apiVersion: monitoring.coreos.com/v1 | ||
kind: PrometheusRule | ||
metadata: | ||
name: {{ template "hermes.fullname" . }} | ||
{{- if .Values.alerting.prometheusRule.namespace }} | ||
namespace: {{ .Values.alerting.prometheusRule.namespace | quote }} | ||
{{- end }} | ||
labels: | ||
{{- include "hermes.labels" . | nindent 4 }} | ||
{{- if .Values.alerting.prometheusRule.additionalLabels }} | ||
{{- toYaml .Values.alerting.prometheusRule.additionalLabels | nindent 4 }} | ||
{{- end }} | ||
spec: | ||
{{- if .Values.alerting.prometheusRule.rules }} | ||
groups: | ||
- name: {{ template "hermes.fullname" . }} | ||
rules: {{- toYaml .Values.alerting.prometheusRule.rules | nindent 4 }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{{- if and .Values.serviceMonitor.enabled .Values.telemetry.enabled }} | ||
apiVersion: monitoring.coreos.com/v1 | ||
kind: ServiceMonitor | ||
metadata: | ||
name: hermes-relayer-metrics | ||
labels: | ||
app: {{ include "hermes.fullname" . }} | ||
{{- with .Values.serviceMonitor.additionalLabels }} | ||
{{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
spec: | ||
jobLabel: hermes-relayer-metric | ||
namespaceSelector: | ||
matchNames: | ||
- {{ include "hermes.namespace" . }} | ||
selector: | ||
matchLabels: | ||
app: {{ include "hermes.fullname" . }} | ||
endpoints: | ||
- port: telemetry | ||
path: /metrics | ||
{{- with .Values.serviceMonitor.interval }} | ||
interval: {{ . }} | ||
{{- end }} | ||
{{- with .Values.serviceMonitor.scrapeTimeout }} | ||
scrapeTimeout: {{ . }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters