mirror of
https://github.com/bitnami/charts.git
synced 2026-02-15 07:47:12 +08:00
[bitnami/apache] Use the new helper for HPA API version (#10192)
* Use the new helper for HPA API version Signed-off-by: Miguel A. Cabrera Minagorri <devgorri@gmail.com> * Contemplate targetAverageUtilization Signed-off-by: Miguel A. Cabrera Minagorri <devgorri@gmail.com>
This commit is contained in:
committed by
GitHub
parent
fc38efa3cb
commit
a2099a5c17
@@ -1,6 +1,6 @@
|
||||
dependencies:
|
||||
- name: common
|
||||
repository: https://charts.bitnami.com/bitnami
|
||||
version: 1.13.0
|
||||
digest: sha256:e83af41b39942278f8389623671732e624f28c6f1ad6ac2d937e210c5f354a18
|
||||
generated: "2022-03-26T23:36:19.001929886Z"
|
||||
version: 1.14.0
|
||||
digest: sha256:965d4465e4039d36637175307a8edfc13a53414d3bb698c0d26c8acc1cf3ec3d
|
||||
generated: "2022-05-13T14:56:07.479929+02:00"
|
||||
|
||||
@@ -26,4 +26,4 @@ name: apache
|
||||
sources:
|
||||
- https://github.com/bitnami/bitnami-docker-apache
|
||||
- https://httpd.apache.org
|
||||
version: 9.0.18
|
||||
version: 9.0.19
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{{- if .Values.autoscaling.enabled }}
|
||||
apiVersion: autoscaling/v2beta1
|
||||
apiVersion: {{ include "common.capabilities.hpa.apiVersion" . }}
|
||||
kind: HorizontalPodAutoscaler
|
||||
metadata:
|
||||
name: {{ template "common.names.fullname" . }}
|
||||
@@ -23,12 +23,24 @@ spec:
|
||||
- type: Resource
|
||||
resource:
|
||||
name: cpu
|
||||
{{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" .) }}
|
||||
targetAverageUtilization: {{ .Values.autoscaling.targetCPU }}
|
||||
{{- else }}
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: {{ .Values.autoscaling.targetCPU }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- if .Values.autoscaling.targetMemory }}
|
||||
- type: Resource
|
||||
resource:
|
||||
name: memory
|
||||
targetAverageUtilization: {{ .Values.autoscaling.targetMemory }}
|
||||
{{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" .) }}
|
||||
targetAverageUtilization: {{ .Values.autoscaling.targetMemory }}
|
||||
{{- else }}
|
||||
target:
|
||||
type: Utilization
|
||||
averageUtilization: {{ .Values.autoscaling.targetMemory }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
||||
Reference in New Issue
Block a user