Skip to content

Commit

Permalink
chore: promtail update
Browse files Browse the repository at this point in the history
Signed-off-by: Micah Nagel <[email protected]>
  • Loading branch information
mjnagel committed May 30, 2024
1 parent d2d9da9 commit fe85838
Show file tree
Hide file tree
Showing 37 changed files with 180 additions and 83 deletions.
46 changes: 24 additions & 22 deletions .github/workflows/update-helm-repo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,15 @@ jobs:
if [ $(git tag -l "${name}-${version}") ]; then
echo "Tag ${tagname} already exists, skipping release"
echo "::set-output name=changed::false"
echo "changed=false" >> $GITHUB_OUTPUT
else
echo "Releasing ${changed}"
echo "::set-output name=changed::true"
echo "::set-output name=chartpath::${changed}"
echo "changed=true" >> $GITHUB_OUTPUT
echo "chartpath=${changed}" >> $GITHUB_OUTPUT
fi
else
echo "No charts have changed, skipping release"
echo "::set-output name=changed::false"
echo "changed=false" >> $GITHUB_OUTPUT
fi
release:
Expand Down Expand Up @@ -145,19 +145,6 @@ jobs:
with:
version: v3.5.2

- name: Add dependency chart repos
# Todo replace this by https://github.com/grafana/helm-charts/issues/1534
run: |
helm repo add elastic https://helm.elastic.co
helm repo add grafana https://grafana.github.io/helm-charts
helm repo add prometheus https://prometheus-community.github.io/helm-charts
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add bitnami-pre-2022 https://raw.githubusercontent.com/bitnami/charts/eb5f9a9513d987b519f0ecd732e7031241c50328/bitnami
helm repo add hashicorp https://helm.releases.hashicorp.com
helm repo add minio-new https://charts.min.io
helm repo add jetstack https://charts.jetstack.io
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
- name: Parse Chart.yaml
id: parse-chart
run: |
Expand All @@ -166,14 +153,29 @@ jobs:
description=$(yq ".description" < ${changed}/Chart.yaml)
name=$(yq ".name" < ${changed}/Chart.yaml)
version=$(yq ".version" < ${changed}/Chart.yaml)
echo "::set-output name=chartpath::${changed}"
echo "::set-output name=desc::${description}"
echo "chartpath=${changed}" >> $GITHUB_OUTPUT
echo "desc=${description}" >> $GITHUB_OUTPUT
if [[ -n "${HELM_TAG_PREFIX}" ]]; then
echo "::set-output name=tagname::${HELM_TAG_PREFIX}-${name}-${version}"
echo "tagname=${HELM_TAG_PREFIX}-${name}-${version}" >> $GITHUB_OUTPUT
else
echo "::set-output name=tagname::${name}-${version}"
echo "tagname=${name}-${version}" >> $GITHUB_OUTPUT
fi
echo "::set-output name=packagename::${name}-${version}"
echo "packagename=${name}-${version}" >> $GITHUB_OUTPUT
- name: Add dependency chart repos
run: |
cd source
# Skip the header line and make sure that tabs are expanded into spaces
deps=$(helm dependency list "${{ steps.parse-chart.outputs.chartpath }}" | tail +2 | expand)
while read -r row; do
IFS=' ' read -ra parts <<< "$row"
name="${parts[0]}"
repo="${parts[2]}"
case "$repo" in
"https://"*) helm repo add "$name" "$repo" ;;
*) echo >&2 "Skipping dependency $name: unsupported schema for \"$repo\"" ;;
esac
done <<< "$deps"
- name: Install CR tool
run: |
Expand Down
8 changes: 4 additions & 4 deletions charts/agent-operator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ apiVersion: v2
name: grafana-agent-operator
description: A Helm chart for Grafana Agent Operator
type: application
version: 0.3.21
appVersion: "0.40.4"
version: 0.3.22
appVersion: "0.40.5"
home: https://grafana.com/docs/agent/v0.40/
icon: https://raw.githubusercontent.com/grafana/agent/v0.40.4/docs/sources/assets/logo_and_name.png
icon: https://raw.githubusercontent.com/grafana/agent/v0.40.5/docs/sources/assets/logo_and_name.png
sources:
- https://github.com/grafana/agent/tree/v0.40.4/pkg/operator
- https://github.com/grafana/agent/tree/v0.40.5/pkg/operator
maintainers:
- name: Grafana Agent Team
email: [email protected]
6 changes: 3 additions & 3 deletions charts/agent-operator/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# grafana-agent-operator

![Version: 0.3.21](https://img.shields.io/badge/Version-0.3.21-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.40.4](https://img.shields.io/badge/AppVersion-0.40.4-informational?style=flat-square)
![Version: 0.3.22](https://img.shields.io/badge/Version-0.3.22-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.40.5](https://img.shields.io/badge/AppVersion-0.40.5-informational?style=flat-square)

A Helm chart for Grafana Agent Operator

⚠️ **Please create issues relating to this Helm chart in the [Agent](https://github.com/grafana/agent/issues) repo.**

## Source Code

* <https://github.com/grafana/agent/tree/v0.40.4/pkg/operator>
* <https://github.com/grafana/agent/tree/v0.40.5/pkg/operator>

Note that this chart does not provision custom resources like `GrafanaAgent` and `MetricsInstance` (formerly `PrometheusInstance`) or any `*Monitor` resources.

Expand Down Expand Up @@ -63,7 +63,7 @@ A major chart version change (like v1.2.3 -> v2.0.0) indicates that there is an
| image.pullSecrets | list | `[]` | Image pull secrets |
| image.registry | string | `"docker.io"` | Image registry |
| image.repository | string | `"grafana/agent-operator"` | Image repo |
| image.tag | string | `"v0.40.4"` | Image tag |
| image.tag | string | `"v0.40.5"` | Image tag |
| kubeletService | object | `{"namespace":"default","serviceName":"kubelet"}` | If both are set, Agent Operator will create and maintain a service for scraping kubelets https://grafana.com/docs/agent/latest/operator/getting-started/#monitor-kubelets |
| nameOverride | string | `""` | Overrides the chart's name |
| nodeSelector | object | `{}` | nodeSelector configuration |
Expand Down
2 changes: 1 addition & 1 deletion charts/agent-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ image:
# -- Image repo
repository: grafana/agent-operator
# -- Image tag
tag: v0.40.4
tag: v0.40.5
# -- Image pull policy
pullPolicy: IfNotPresent
# -- Image pull secrets
Expand Down
2 changes: 1 addition & 1 deletion charts/grafana-sampling/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: grafana-sampling
description: A Helm chart for a layered OTLP tail sampling and metrics generation pipeline.
type: application
version: 0.1.0
version: 0.1.1
appVersion: "v0.40.2"
sources:
- https://github.com/grafana/agent
Expand Down
2 changes: 1 addition & 1 deletion charts/grafana-sampling/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# grafana-sampling

![Version: 0.1.0](https://img.shields.io/badge/Version-0.1.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.40.2](https://img.shields.io/badge/AppVersion-v0.40.2-informational?style=flat-square)
![Version: 0.1.1](https://img.shields.io/badge/Version-0.1.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.40.2](https://img.shields.io/badge/AppVersion-v0.40.2-informational?style=flat-square)

A Helm chart for a layered OTLP tail sampling and metrics generation pipeline.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ otelcol.processor.batch "default" {
otelcol.processor.batch "default" {
// https://grafana.com/docs/agent/latest/flow/reference/components/otelcol.processor.batch/
output {
{{ if .Values.metricsGeneration.Enabled }}
{{ if .Values.metricsGeneration.enabled }}
metrics = [otelcol.exporter.prometheus.grafana_cloud_prometheus.input]
{{ end }}
traces = [otelcol.exporter.otlp.grafana_cloud_tempo.input]
Expand Down
2 changes: 1 addition & 1 deletion charts/grafana/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: grafana
version: 7.3.8
version: 7.3.11
appVersion: 10.4.1
kubeVersion: "^1.8.0-0"
description: The leading tool for querying and visualizing time series and metrics.
Expand Down
12 changes: 5 additions & 7 deletions charts/grafana/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -145,13 +145,11 @@ Return the appropriate apiVersion for ingress.
Return the appropriate apiVersion for Horizontal Pod Autoscaler.
*/}}
{{- define "grafana.hpa.apiVersion" -}}
{{- if $.Capabilities.APIVersions.Has "autoscaling/v2/HorizontalPodAutoscaler" }}
{{- print "autoscaling/v2" }}
{{- else if $.Capabilities.APIVersions.Has "autoscaling/v2beta2/HorizontalPodAutoscaler" }}
{{- print "autoscaling/v2beta2" }}
{{- else }}
{{- print "autoscaling/v2beta1" }}
{{- end }}
{{- if .Capabilities.APIVersions.Has "autoscaling/v2" }}
{{- print "autoscaling/v2" }}
{{- else }}
{{- print "autoscaling/v2beta2" }}
{{- end }}
{{- end }}
{{/*
Expand Down
3 changes: 3 additions & 0 deletions charts/grafana/templates/pvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
resources:
requests:
storage: {{ .Values.persistence.size | quote }}
{{- if (lookup "v1" "PersistentVolumeClaim" (include "grafana.namespace" .) (include "grafana.fullname" .)) }}
volumeName: {{ (lookup "v1" "PersistentVolumeClaim" (include "grafana.namespace" .) (include "grafana.fullname" .)).spec.volumeName }}
{{- end }}
{{- with .Values.persistence.storageClassName }}
storageClassName: {{ . }}
{{- end }}
Expand Down
4 changes: 4 additions & 0 deletions charts/grafana/templates/tests/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ spec:
- mountPath: /tests
name: tests
readOnly: true
{{- with .Values.testFramework.resources }}
resources:
{{- toYaml . | nindent 8 }}
{{- end }}
volumes:
- name: tests
configMap:
Expand Down
7 changes: 7 additions & 0 deletions charts/grafana/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,13 @@ testFramework:
tag: "v1.4.1"
imagePullPolicy: IfNotPresent
securityContext: {}
resources: {}
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi

# dns configuration for pod
dnsPolicy: ~
Expand Down
2 changes: 1 addition & 1 deletion charts/loki-distributed/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: loki-distributed
description: Helm chart for Grafana Loki in microservices mode
type: application
appVersion: 2.9.6
version: 0.78.5
version: 0.79.0
home: https://grafana.github.io/helm-charts
sources:
- https://github.com/grafana/loki
Expand Down
5 changes: 4 additions & 1 deletion charts/loki-distributed/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# loki-distributed

![Version: 0.78.5](https://img.shields.io/badge/Version-0.78.5-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: 0.79.0](https://img.shields.io/badge/Version-0.79.0-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 microservices mode

Expand All @@ -24,6 +24,9 @@ helm repo add grafana https://grafana.github.io/helm-charts

Major version upgrades listed here indicate that there is an incompatible breaking change needing manual actions.

### From 0.78.x to 0.79.0
Removed the hardcoded, deprecated `boltdb.shipper.compactor.working-directory` flag in the Compactor Deployment template, so that it can be set with `.Values.compactor.extraArgs` and the `compactor.working-directory` flag if necessary.

### From 0.74.x to 0.75.0
The Index Gateway and Query Scheduler now expose the memberlist port 7946. In order to join the
member list, you need to specify this in the `structuredConfig`:
Expand Down
3 changes: 3 additions & 0 deletions charts/loki-distributed/README.md.gotmpl
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ helm repo add grafana https://grafana.github.io/helm-charts

Major version upgrades listed here indicate that there is an incompatible breaking change needing manual actions.

### From 0.78.x to 0.79.0
Removed the hardcoded, deprecated `boltdb.shipper.compactor.working-directory` flag in the Compactor Deployment template, so that it can be set with `.Values.compactor.extraArgs` and the `compactor.working-directory` flag if necessary.

### From 0.74.x to 0.75.0
The Index Gateway and Query Scheduler now expose the memberlist port 7946. In order to join the
member list, you need to specify this in the `structuredConfig`:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ spec:
args:
- -config.file=/etc/loki/config/config.yaml
- -target=compactor
- -boltdb.shipper.compactor.working-directory=/var/loki/compactor
{{- with .Values.compactor.extraArgs }}
{{- toYaml . | nindent 12 }}
{{- end }}
Expand Down
1 change: 1 addition & 0 deletions charts/loki-distributed/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ loki:
compactor:
shared_store: filesystem
working_directory: /var/loki/compactor
ruler:
storage:
Expand Down
4 changes: 2 additions & 2 deletions charts/promtail/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ apiVersion: v2
name: promtail
description: Promtail is an agent which ships the contents of local logs to a Loki instance
type: application
appVersion: 2.9.3
version: 6.15.5
appVersion: 3.0.0
version: 6.16.0
home: https://grafana.com/loki
sources:
- https://github.com/grafana/loki
Expand Down
9 changes: 6 additions & 3 deletions charts/promtail/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# promtail

![Version: 6.15.5](https://img.shields.io/badge/Version-6.15.5-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.9.3](https://img.shields.io/badge/AppVersion-2.9.3-informational?style=flat-square)
![Version: 6.16.0](https://img.shields.io/badge/Version-6.16.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 3.0.0](https://img.shields.io/badge/AppVersion-3.0.0-informational?style=flat-square)

Promtail is an agent which ships the contents of local logs to a Loki instance

Expand Down Expand Up @@ -143,6 +143,9 @@ The new release which will pick up again from the existing `positions.yaml`.
| resources | object | `{}` | Resource requests and limits |
| secret.annotations | object | `{}` | Annotations for the Secret |
| secret.labels | object | `{}` | Labels for the Secret |
| service.annotations | object | `{}` | Annotations for the service |
| service.enabled | bool | `false` | |
| service.labels | object | `{}` | Labels for the service |
| serviceAccount.annotations | object | `{}` | Annotations for the service account |
| serviceAccount.create | bool | `true` | Specifies whether a ServiceAccount should be created |
| serviceAccount.imagePullSecrets | list | `[]` | Image pull secrets for the service account |
Expand All @@ -167,9 +170,9 @@ The new release which will pick up again from the existing `positions.yaml`.
| sidecar.configReloader.extraEnv | list | `[]` | Extra environment variables for sidecar config-reloader |
| sidecar.configReloader.extraEnvFrom | list | `[]` | Extra environment variables from secrets or configmaps for sidecar config-reloader |
| sidecar.configReloader.image.pullPolicy | string | `"IfNotPresent"` | Docker image pull policy for sidecar config-reloader |
| sidecar.configReloader.image.registry | string | `"docker.io"` | The Docker registry for sidecar config-reloader |
| sidecar.configReloader.image.registry | string | `"ghcr.io"` | The Docker registry for sidecar config-reloader |
| sidecar.configReloader.image.repository | string | `"jimmidyson/configmap-reload"` | Docker image repository for sidecar config-reloader |
| sidecar.configReloader.image.tag | string | `"v0.8.0"` | Docker image tag for sidecar config-reloader |
| sidecar.configReloader.image.tag | string | `"v0.12.0"` | Docker image tag for sidecar config-reloader |
| sidecar.configReloader.livenessProbe | object | `{}` | Liveness probe for sidecar config-reloader |
| sidecar.configReloader.readinessProbe | object | `{}` | Readiness probe for sidecar config-reloader |
| sidecar.configReloader.resources | object | `{}` | Resource requests and limits for sidecar config-reloader |
Expand Down
5 changes: 4 additions & 1 deletion charts/promtail/templates/service-metrics.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
{{- if .Values.serviceMonitor.enabled }}
{{- if or .Values.serviceMonitor.enabled .Values.service.enabled }}
apiVersion: v1
kind: Service
metadata:
name: {{ include "promtail.fullname" . }}-metrics
namespace: {{ include "promtail.namespaceName" . }}
labels:
{{- include "promtail.labels" . | nindent 4 }}
{{- toYaml .Values.service.labels | nindent 4 }}
annotations:
{{- toYaml .Values.service.annotations | nindent 4 }}
spec:
clusterIP: None
ports:
Expand Down
11 changes: 9 additions & 2 deletions charts/promtail/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,13 @@ deployment:
strategy:
type: RollingUpdate

service:
enabled: false
# -- Labels for the service
labels: {}
# -- Annotations for the service
annotations: {}

secret:
# -- Labels for the Secret
labels: {}
Expand Down Expand Up @@ -584,11 +591,11 @@ sidecar:
enabled: false
image:
# -- The Docker registry for sidecar config-reloader
registry: docker.io
registry: ghcr.io
# -- Docker image repository for sidecar config-reloader
repository: jimmidyson/configmap-reload
# -- Docker image tag for sidecar config-reloader
tag: v0.8.0
tag: v0.12.0
# -- Docker image pull policy for sidecar config-reloader
pullPolicy: IfNotPresent
# Extra args for the config-reloader container.
Expand Down
4 changes: 2 additions & 2 deletions charts/tempo-distributed/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ apiVersion: v2
name: tempo-distributed
description: Grafana Tempo in MicroService mode
type: application
version: 1.9.2
appVersion: 2.4.1
version: 1.9.11
appVersion: 2.4.2
engine: gotpl
home: https://grafana.com/docs/tempo/latest/
icon: https://raw.githubusercontent.com/grafana/tempo/master/docs/tempo/website/logo_and_name.png
Expand Down
Loading

0 comments on commit fe85838

Please sign in to comment.