25 lines
776 B
YAML

{{- if .Values.grafana.enabled }}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "open-meteo-service.grafanaFullname" . }}-config
labels:
{{- include "open-meteo-service.labels" . | nindent 4 }}
app.kubernetes.io/component: grafana
data:
datasource.yml: |-
apiVersion: 1
datasources:
- name: Prometheus
type: prometheus
access: proxy
url: http://{{ include "open-meteo-service.prometheusFullname" . }}:{{ .Values.prometheus.service.port }}
isDefault: true
uid: prometheus
dashboard.yml: |-
{{ .Files.Get "files/grafana/provisioning/dashboards/dashboard.yml" | nindent 4 }}
open-meteo-service.json: |-
{{ .Files.Get "files/grafana/dashboards/open-meteo-service.json" | nindent 4 }}
{{- end }}