From d383d81f9bef5543de0c5819a2731aecaeeafdd7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gy=C3=B6rgy=20Krajcsovits?= Date: Thu, 23 Jun 2022 10:42:39 +0200 Subject: [PATCH] Helm: add NOTES.txt MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a NOTES.txt that prints the endpoints that will be usable by the user for interacting with mimir/gem. Currently helm does not support rendering the NOTES for testing. Rage/vote here: https://github.com/helm/helm/issues/6901 Signed-off-by: György Krajcsovits --- .../mimir-distributed/templates/NOTES.txt | 33 +++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 operations/helm/charts/mimir-distributed/templates/NOTES.txt diff --git a/operations/helm/charts/mimir-distributed/templates/NOTES.txt b/operations/helm/charts/mimir-distributed/templates/NOTES.txt new file mode 100644 index 0000000000..e88b43aa71 --- /dev/null +++ b/operations/helm/charts/mimir-distributed/templates/NOTES.txt @@ -0,0 +1,33 @@ +{{- $gateway := .Values.nginx }} +{{- if .Values.enterprise.enabled }} +{{- $gateway = .Values.gateway }} +Welcome to Grafana Enterprise Metrics! +{{- else }} +Welcome to Grafana Mimir! +{{- end }} + +Remote write endpoints for Prometheus or Grafana Agent: +{{ with $gateway.ingress -}} +{{- if .enabled -}} +From outside the cluster via ingress: +{{ range .hosts }} http{{ if .tls }}s{{ end }}://{{ .host }}/api/v1/push +{{ end }} +{{- else -}} +Ingress is not enabled, see {{ if $.Values.enterprise.enabled }}gateway.ingress{{ else }}nginx.ingress{{ end }} values. +{{- end -}} +{{- end }} +From inside the cluster: + http://{{ include "mimir.fullname" $ }}-{{ if .Values.enterprise.enabled }}gateway{{ else }}nginx{{ end }}.{{ .Release.Namespace }}.svc:{{ $gateway.service.port | default "80" }}/api/v1/push + +Read address, Grafana data source (Prometheus) URL: +{{ with $gateway.ingress -}} +{{- if .enabled -}} +From outside the cluster via ingress: +{{ range .hosts }} http{{ if .tls }}s{{ end }}://{{ .host }}/prometheus +{{ end }} +{{- else -}} +Ingress is not enabled, see {{ if $.Values.enterprise.enabled }}gateway.ingress{{ else }}nginx.ingress{{ end }} values. +{{- end -}} +{{- end }} +From inside the cluster: + http://{{ include "mimir.fullname" $ }}-{{ if .Values.enterprise.enabled }}gateway{{ else }}nginx{{ end }}.{{ .Release.Namespace }}.svc:{{ $gateway.service.port | default "80" }}/prometheus \ No newline at end of file