Grafana 8.5.10 with unified alerting

This PS updates Grafana to 8.5.10 and enables unified alerting
which will be the default in 9.x.

The following directories are required for unified alerting:
/var/lib/grafana/alerting
/var/lib/grafana/csv

If a user is upgrading from Grafana 7.x and wants to opt out of unified
alerting they will need to set:

[alerting]
enabled = true
[unified_alerting]
enabled = false

in grafana.ini. Additionally, to roll back, the env var

GF_DEFAULT_FORCE_MIGRATION: true

needs to be set for the grafana_run_migrator pod.

Unified alerting doc:

https://grafana.com/docs/grafana/v9.0/alerting/migrating-alerts/

Change-Id: I3a6ca005b9d9433e958802e7e978b81479a16fb8
This commit is contained in:
Ritchie, Frank (fr801x) 2022-08-23 16:14:27 -04:00
parent 07e25f44d0
commit 818c475f1d
5 changed files with 31 additions and 3 deletions

View File

@ -12,10 +12,10 @@
--- ---
apiVersion: v1 apiVersion: v1
appVersion: v7.4.5 appVersion: v8.5.10
description: OpenStack-Helm Grafana description: OpenStack-Helm Grafana
name: grafana name: grafana
version: 0.1.15 version: 0.1.16
home: https://grafana.com/ home: https://grafana.com/
sources: sources:
- https://github.com/grafana/grafana - https://github.com/grafana/grafana

View File

@ -102,6 +102,10 @@ spec:
mountPath: /etc/grafana/dashboards mountPath: /etc/grafana/dashboards
- name: pod-provisioning-grafana - name: pod-provisioning-grafana
mountPath: {{ .Values.conf.grafana.paths.provisioning }} mountPath: {{ .Values.conf.grafana.paths.provisioning }}
- name: pod-alerting-grafana
mountPath: {{ .Values.conf.grafana.paths.alerting }}
- name: pod-csv-grafana
mountPath: {{ .Values.conf.grafana.paths.csv }}
- name: grafana-bin - name: grafana-bin
mountPath: /tmp/grafana.sh mountPath: /tmp/grafana.sh
subPath: grafana.sh subPath: grafana.sh
@ -141,6 +145,10 @@ spec:
emptyDir: {} emptyDir: {}
- name: pod-provisioning-grafana - name: pod-provisioning-grafana
emptyDir: {} emptyDir: {}
- name: pod-alerting-grafana
emptyDir: {}
- name: pod-csv-grafana
emptyDir: {}
- name: grafana-bin - name: grafana-bin
configMap: configMap:
name: grafana-bin name: grafana-bin

View File

@ -84,6 +84,9 @@ spec:
{{- end }} {{- end }}
{{- if .Values.pod.env.grafana }} {{- if .Values.pod.env.grafana }}
{{ include "helm-toolkit.utils.to_k8s_env_vars" .Values.pod.env.grafana | indent 12 }} {{ include "helm-toolkit.utils.to_k8s_env_vars" .Values.pod.env.grafana | indent 12 }}
{{- end }}
{{- if .Values.pod.env.grafana_run_migrator }}
{{ include "helm-toolkit.utils.to_k8s_env_vars" .Values.pod.env.grafana_run_migrator | indent 12 }}
{{- end }} {{- end }}
volumeMounts: volumeMounts:
- name: pod-tmp - name: pod-tmp
@ -96,6 +99,10 @@ spec:
mountPath: /etc/grafana/dashboards mountPath: /etc/grafana/dashboards
- name: pod-provisioning-grafana - name: pod-provisioning-grafana
mountPath: {{ .Values.conf.grafana.paths.provisioning }} mountPath: {{ .Values.conf.grafana.paths.provisioning }}
- name: pod-alerting-grafana
mountPath: {{ .Values.conf.grafana.paths.alerting }}
- name: pod-csv-grafana
mountPath: {{ .Values.conf.grafana.paths.csv }}
- name: grafana-bin - name: grafana-bin
mountPath: /tmp/grafana.sh mountPath: /tmp/grafana.sh
subPath: grafana.sh subPath: grafana.sh
@ -135,6 +142,10 @@ spec:
emptyDir: {} emptyDir: {}
- name: pod-provisioning-grafana - name: pod-provisioning-grafana
emptyDir: {} emptyDir: {}
- name: pod-alerting-grafana
emptyDir: {}
- name: pod-csv-grafana
emptyDir: {}
- name: grafana-bin - name: grafana-bin
configMap: configMap:
name: grafana-bin name: grafana-bin

View File

@ -17,7 +17,7 @@
--- ---
images: images:
tags: tags:
grafana: docker.io/grafana/grafana:7.4.5 grafana: docker.io/grafana/grafana:8.5.10
dep_check: quay.io/airshipit/kubernetes-entrypoint:v1.0.0 dep_check: quay.io/airshipit/kubernetes-entrypoint:v1.0.0
db_init: docker.io/openstackhelm/heat:stein-ubuntu_bionic db_init: docker.io/openstackhelm/heat:stein-ubuntu_bionic
grafana_db_session_sync: docker.io/openstackhelm/heat:stein-ubuntu_bionic grafana_db_session_sync: docker.io/openstackhelm/heat:stein-ubuntu_bionic
@ -44,6 +44,8 @@ labels:
pod: pod:
env: env:
grafana: null grafana: null
grafana_run_migrator:
GF_DEFAULT_FORCE_MIGRATION: false
security_context: security_context:
dashboard: dashboard:
pod: pod:
@ -485,6 +487,10 @@ conf:
basicAuthPassword: {{ .Values.endpoints.monitoring.auth.user.password }} basicAuthPassword: {{ .Values.endpoints.monitoring.auth.user.password }}
url: {{ tuple "monitoring" "internal" "api" . | include "helm-toolkit.endpoints.keystone_endpoint_uri_lookup" }} url: {{ tuple "monitoring" "internal" "api" . | include "helm-toolkit.endpoints.keystone_endpoint_uri_lookup" }}
grafana: grafana:
alerting:
enabled: false
unified_alerting:
enabled: true
analytics: analytics:
reporting_enabled: false reporting_enabled: false
check_for_updates: false check_for_updates: false
@ -494,6 +500,8 @@ conf:
paths: paths:
data: /var/lib/grafana/data data: /var/lib/grafana/data
plugins: /var/lib/grafana/plugins plugins: /var/lib/grafana/plugins
alerting: /var/lib/grafana/alerting
csv: /var/lib/grafana/csv
provisioning: /etc/grafana/provisioning provisioning: /etc/grafana/provisioning
server: server:
protocol: http protocol: http

View File

@ -16,4 +16,5 @@ grafana:
- 0.1.13 Update prometheus metric name - 0.1.13 Update prometheus metric name
- 0.1.14 Add run migrator job - 0.1.14 Add run migrator job
- 0.1.15 Added OCI registry authentication - 0.1.15 Added OCI registry authentication
- 0.1.16 Grafana 8.5.10 with unified alerting
... ...