From 111c19b38147837041c6cc7c7483abe00c0c1599 Mon Sep 17 00:00:00 2001 From: Danny Kopping Date: Thu, 28 Mar 2024 13:02:24 +0200 Subject: [PATCH] feat(helm): add support for additional `PodLogs` pipeline stages in `selfMonitoring` (#12389) Signed-off-by: Danny Kopping --- docs/sources/setup/install/helm/reference.md | 9 +++++++++ production/helm/loki/CHANGELOG.md | 4 ++++ production/helm/loki/Chart.yaml | 2 +- production/helm/loki/README.md | 2 +- production/helm/loki/templates/monitoring/pod-logs.yaml | 3 +++ production/helm/loki/values.yaml | 3 +++ 6 files changed, 21 insertions(+), 2 deletions(-) diff --git a/docs/sources/setup/install/helm/reference.md b/docs/sources/setup/install/helm/reference.md index 62f474672f446..d44ee934d0c92 100644 --- a/docs/sources/setup/install/helm/reference.md +++ b/docs/sources/setup/install/helm/reference.md @@ -2851,6 +2851,15 @@ null
 {}
 
+ + + + monitoring.selfMonitoring.podLogs.additionalPipelineStages + list + Additional pipeline stages to process logs after scraping https://grafana.com/docs/agent/latest/operator/api/#pipelinestagespec-a-namemonitoringgrafanacomv1alpha1pipelinestagespeca +
+[]
+
diff --git a/production/helm/loki/CHANGELOG.md b/production/helm/loki/CHANGELOG.md index 7f8a5043c1505..60ff91c766e1e 100644 --- a/production/helm/loki/CHANGELOG.md +++ b/production/helm/loki/CHANGELOG.md @@ -13,6 +13,10 @@ Entries should include a reference to the pull request that introduced the chang [//]: # ( : do not remove this line. This locator is used by the CI pipeline to automatically create a changelog entry for each new Loki release. Add other chart versions and respective changelog entries bellow this line.) +## 5.47.2 + +- [ENHANCEMENT] Allow for additional pipeline stages to be configured on the `selfMonitoring` `Podlogs` resource. + ## 5.47.1 - [BUGFIX] Increase default value of backend minReplicas to 3 diff --git a/production/helm/loki/Chart.yaml b/production/helm/loki/Chart.yaml index 6b3423e2cca15..21972fe007099 100644 --- a/production/helm/loki/Chart.yaml +++ b/production/helm/loki/Chart.yaml @@ -3,7 +3,7 @@ name: loki description: Helm chart for Grafana Loki in simple, scalable mode type: application appVersion: 2.9.6 -version: 5.47.1 +version: 5.47.2 home: https://grafana.github.io/helm-charts sources: - https://github.com/grafana/loki diff --git a/production/helm/loki/README.md b/production/helm/loki/README.md index cdafd290f3685..942498d471476 100644 --- a/production/helm/loki/README.md +++ b/production/helm/loki/README.md @@ -1,6 +1,6 @@ # loki -![Version: 5.47.1](https://img.shields.io/badge/Version-5.47.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.9.6](https://img.shields.io/badge/AppVersion-2.9.6-informational?style=flat-square) +![Version: 5.47.2](https://img.shields.io/badge/Version-5.47.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.9.6](https://img.shields.io/badge/AppVersion-2.9.6-informational?style=flat-square) Helm chart for Grafana Loki in simple, scalable mode diff --git a/production/helm/loki/templates/monitoring/pod-logs.yaml b/production/helm/loki/templates/monitoring/pod-logs.yaml index 3fc95c44e22b6..317339d7668f9 100644 --- a/production/helm/loki/templates/monitoring/pod-logs.yaml +++ b/production/helm/loki/templates/monitoring/pod-logs.yaml @@ -18,6 +18,9 @@ metadata: spec: pipelineStages: - cri: { } + {{- with .additionalPipelineStages }} + {{- toYaml . | nindent 4 }} + {{- end }} relabelings: - action: replace sourceLabels: diff --git a/production/helm/loki/values.yaml b/production/helm/loki/values.yaml index 04d2660917299..70d853bca2ce8 100644 --- a/production/helm/loki/values.yaml +++ b/production/helm/loki/values.yaml @@ -691,6 +691,9 @@ monitoring: # -- PodLogs relabel configs to apply to samples before scraping # https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/api.md#relabelconfig relabelings: [] + # -- Additional pipeline stages to process logs after scraping + # https://grafana.com/docs/agent/latest/operator/api/#pipelinestagespec-a-namemonitoringgrafanacomv1alpha1pipelinestagespeca + additionalPipelineStages: [] # LogsInstance configuration logsInstance: # -- LogsInstance annotations