github grafana/grafana-operator v5.22.0

10 hours ago

We're happy to announce version 5.22.0 of the Grafana Operator!

This release contains a bunch of new and exciting features like:

  • The brand new GrafanaManifest resource
    • This allows you to manage resources previously not supported by the operator but available through the new Kuberentes-style Grafana APIs (e.g Playlists, ShortURLs) as well as resources introduced by plugins (e.g. Frontend O11y configuration in Grafana Cloud).
  • Dynamic resource patching (currently only available to GrafanaManifest resources)
    • Patch resources with arbitrary jq scripts before submitting them to the Grafana API!
  • Alert rule groups have been updated to support more fields exposed by the Grafana API
  • Service accounts no longer require a name and will default to metadata.name

Upgrade instructions

Using Helm

# Upgrade the operator image & deployment
helm upgrade -i grafana-operator oci://ghcr.io/grafana/helm-charts/grafana-operator --version 5.22.0
# Upgrading CRDs
kubectl apply --server-side --force-conflicts -f https://github.com/grafana/grafana-operator/releases/download/v5.22.0/crds.yaml

Using kubectl

# Namespace Scope
kubectl replace -f https://github.com/grafana/grafana-operator/releases/download/v5.22.0/kustomize-namespace_scoped.yaml
# Cluster Scope
kubectl replace -f https://github.com/grafana/grafana-operator/releases/download/v5.22.0/kustomize-cluster_scoped.yaml 

Using kustomize

flux pull artifact oci://ghcr.io/grafana/kustomize/grafana-operator:v5.22.0 --output ./grafana-operator/

Using OLM

Releases are published to operatorhub.io as well as the OpenShift Operator Catalog. Depending on the installation, existing installations will either upgrade automatically or require approval from an administrator.

What's Changed

Changes that might need your attention

  • chore(Helm): simplify helm chart by @Baarsgaard in #2463
    • We changed the default fallback for the cache strategy to safe instead of off. If you haven't explicitly set enforceCacheLabels to null, this does not affect you.

Features

  • feat(controllers): add new GrafanaManifest resource by @theSuess in #2448
  • feat(GrafanaAlertRuleGroup): add support for targetDatasourceUid in recording rules by @RobertClarke64 in #2478
  • feat(GrafanaAlertRuleGroup): add support for active_time_intervals in notificationSettings by @heliapb in #2479
  • feat(GrafanaManifest): add support for dynamic resource patching by @theSuess in #2470
  • feat(GrafanaServiceAccount): Make .spec.name optional by @Baarsgaard in #2524

Fixes

  • fix(GrafanaDashboard): update Grafana status even when remote state matches by @weisdd in #2440
  • fix(AlertRuleGroup): skip reconciliation when there's no drift in remote state by @heliapb in #2439
  • fix(GrafanaAlertRuleGroup): allow deprecated fields dashboardUid and panelId by @Baarsgaard in #2450
  • fix(logs): Leader election log format by @Baarsgaard in #2466
  • fix: add CRD validation for URLs in external grafana, dashboards, and library panels by @heliapb in #2446
  • fix(GrafanaManifest): consider forbidden error as success when deleting manifests by @theSuess in #2468
  • fix(helm): missing list namespaces permission with watchNamespaceSelector by @Baarsgaard in #2465
  • fix(Grafana): missing HTTPRoute backendRefs (alternative solution) by @weisdd in #2510
  • fix(GrafanaContactPoint): use list based matching as a workaround for 10.4.0-10.4.5 by @theSuess in #2507

Dependencies

  • chore(deps): update dependency ko-build/ko to v0.18.1 by @renovate-sh-app[bot] in #2422
  • chore(deps): update dependency kubernetes-sigs/controller-tools to v1.35.0 by @renovate-sh-app[bot] in #2425
  • chore(deps): update dependency kubernetes-sigs/controller-tools to v0.20.0 by @renovate-sh-app[bot] in #2424
  • chore(deps): update docker.io/grafana/grafana docker tag to v12.3.1 by @renovate-sh-app[bot] in #2423
  • fix(deps): update kubernetes packages to v0.35.0 by @renovate-sh-app[bot] in #2427
  • fix(deps): update module github.com/onsi/ginkgo/v2 to v2.27.4 by @renovate-sh-app[bot] in #2434
  • fix(deps): update module github.com/onsi/ginkgo/v2 to v2.27.5 by @renovate-sh-app[bot] in #2441
  • fix(deps): update module github.com/grafana/grafana-plugin-sdk-go to v0.285.0 by @renovate-sh-app[bot] in #2444
  • chore: bump go to 1.25.6 by @weisdd in #2445
  • chore(deps): update dependency kubernetes-sigs/controller-runtime to v0.22.5 by @renovate-sh-app[bot] in #2454
  • fix(deps): update module sigs.k8s.io/controller-runtime to v0.22.5 by @renovate-sh-app[bot] in #2455
  • chore(deps): update dependency kubernetes-sigs/controller-runtime to v0.23.0 by @renovate-sh-app[bot] in #2458
  • fix(deps): update module sigs.k8s.io/controller-runtime to v0.23.0 by @renovate-sh-app[bot] in #2459
  • fix(deps): update module github.com/grafana/grafana-plugin-sdk-go to v0.286.0 by @renovate-sh-app[bot] in #2462
  • chore(deps): update dependency kubernetes-sigs/controller-runtime to v0.23.1 by @renovate-sh-app[bot] in #2471
  • fix(deps): update module sigs.k8s.io/controller-runtime to v0.23.1 by @renovate-sh-app[bot] in #2472
  • chore(deps): update docker.io/grafana/grafana docker tag to v12.3.2 by @renovate-sh-app[bot] in #2475
  • fix(deps): update module github.com/onsi/ginkgo/v2 to v2.28.1 by @renovate-sh-app[bot] in #2477
  • fix(deps): update module github.com/grafana/grafana-plugin-sdk-go to v0.287.0 by @renovate-sh-app[bot] in #2487
  • fix(deps): update module github.com/alecthomas/kong to v1.14.0 by @renovate-sh-app[bot] in #2488
  • fix(deps): update module k8s.io/apimachinery to v0.35.1 by @renovate-sh-app[bot] in #2492
  • chore(deps): update dependency kubernetes-sigs/kustomize to v5.8.1 by @renovate-sh-app[bot] in #2496
  • fix(deps): update kubernetes packages to v0.35.1 by @renovate-sh-app[bot] in #2498
  • fix(deps): update module k8s.io/apiextensions-apiserver to v0.35.1 by @renovate-sh-app[bot] in #2499
  • fix(deps): update module github.com/grafana/grafana-plugin-sdk-go to v0.288.0 by @renovate-sh-app[bot] in #2500
  • chore(deps): update docker.io/grafana/grafana docker tag to v12.3.3 by @renovate-sh-app[bot] in #2502
  • fix(deps): update module github.com/grafana/grafana-plugin-sdk-go to v0.288.0 by @renovate-sh-app[bot] in #2505
  • chore(deps): update dependency kubernetes-sigs/controller-tools to v0.20.1 by @renovate-sh-app[bot] in #2509
  • chore(deps): update grafana/shared-workflows/get-vault-secrets action to v1.3.1 by @renovate-sh-app[bot] in #2526
  • chore(deps): lock file maintenance by @renovate-sh-app[bot] in #2503

Documentation

Other Changes

  • chore(Makefile): switch deploy target to to its own overlay by @weisdd in #2419
  • chore(controllers): move test container creation to tk8s package by @weisdd in #2443
  • chore(controllers): Refactor creation of HTTP Clients by @Baarsgaard in #2449
  • chore(controllers): normalize logging by @Baarsgaard in #2382
  • chore(helm): reduce the number of RBAC resources by @Baarsgaard in #2464
  • chore(RBAC Kustomize/OpenShift): Only allow lease management within the operators current namespace by @Baarsgaard in #2467
  • chore(api, controllers): modernize code using Go 1.26 features by @weisdd in #2497
  • feat(tests): add support for grafana version overrides by @weisdd in #2490
  • chore(controllers): embed gtime to cut build time by @weisdd in #2514
  • refactor: use kyaml instead of simplejson for fieldpath by @theSuess in #2519

New Contributors

Full Changelog: v5.21.4...v5.22.0

Don't miss a new grafana-operator release

NewReleases is sending notifications on new releases.