Skip to content

Commit 20f01bc

Browse files
mattgialelisJSticklerMichelHollands
authored andcommitted
fix: Add missing Helm helper loki.hpa.apiVersion (#12755)
Co-authored-by: J Stickler <[email protected]> Co-authored-by: Michel Hollands <[email protected]>
1 parent b603313 commit 20f01bc

File tree

4 files changed

+19
-2
lines changed

4 files changed

+19
-2
lines changed

production/helm/loki/CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ Entries should include a reference to the pull request that introduced the chang
1313

1414
[//]: # (<AUTOMATED_UPDATES_LOCATOR> : 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.)
1515

16+
## 6.4.2
17+
18+
- [BUGFIX] Fixed helm helper functions to include missing `loki.hpa.apiVersion` #12716
19+
1620
## 6.4.1
1721

1822
- [BUGFIX] Fixes read & backend replicas settings

production/helm/loki/Chart.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: loki
33
description: Helm chart for Grafana Loki in simple, scalable mode
44
type: application
55
appVersion: 3.0.0
6-
version: 6.4.1
6+
version: 6.4.2
77
home: https://grafana.github.io/helm-charts
88
sources:
99
- https://github.com/grafana/loki

production/helm/loki/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# loki
22

3-
![Version: 6.4.1](https://img.shields.io/badge/Version-6.4.1-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)
3+
![Version: 6.4.2](https://img.shields.io/badge/Version-6.4.2-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)
44

55
Helm chart for Grafana Loki in simple, scalable mode
66

production/helm/loki/templates/_helpers.tpl

+13
Original file line numberDiff line numberDiff line change
@@ -1007,3 +1007,16 @@ Return the object store type for use with the test schema.
10071007
filesystem
10081008
{{- end -}}
10091009
{{- end -}}
1010+
1011+
{{/*
1012+
Return the appropriate apiVersion for HorizontalPodAutoscaler.
1013+
*/}}
1014+
{{- define "loki.hpa.apiVersion" -}}
1015+
{{- if and (.Capabilities.APIVersions.Has "autoscaling/v2") (semverCompare ">= 1.19-0" .Capabilities.KubeVersion.Version) -}}
1016+
{{- print "autoscaling/v2" -}}
1017+
{{- else if .Capabilities.APIVersions.Has "autoscaling/v2beta2" -}}
1018+
{{- print "autoscaling/v2beta2" -}}
1019+
{{- else -}}
1020+
{{- print "autoscaling/v2beta1" -}}
1021+
{{- end -}}
1022+
{{- end -}}

0 commit comments

Comments
 (0)