Skip to content

Commit

Permalink
fix(template): hpa context and path to hpa settings (bitnami#30843)
Browse files Browse the repository at this point in the history
Signed-off-by: Simon Leonard <[email protected]>
  • Loading branch information
sinux-l5d authored Dec 12, 2024
1 parent b6067b1 commit ec253b2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions template/CHART_NAME/templates/hpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ SPDX-License-Identifier: APACHE-2.0
*/}}

{{- if .Values.%%MAIN_OBJECT_BLOCK%%.autoscaling.hpa.enabled }}
apiVersion: {{ include "common.capabilities.hpa.apiVersion" . }}
apiVersion: {{ include "common.capabilities.hpa.apiVersion" ( dict "context" $ ) }}
kind: HorizontalPodAutoscaler
metadata:
name: {{ include "common.names.fullname" . }}
Expand All @@ -31,7 +31,7 @@ spec:
{{- else }}
target:
type: Utilization
averageUtilization: {{ .Values.worker.autoscaling.hpa.targetMemory }}
averageUtilization: {{ .Values.%%MAIN_OBJECT_BLOCK%%.autoscaling.hpa.targetMemory }}
{{- end }}
{{- end }}
{{- if .Values.%%MAIN_OBJECT_BLOCK%%.autoscaling.hpa.targetCPU }}
Expand All @@ -43,7 +43,7 @@ spec:
{{- else }}
target:
type: Utilization
averageUtilization: {{ .Values.worker.autoscaling.hpa.targetCPU }}
averageUtilization: {{ .Values.%%MAIN_OBJECT_BLOCK%%.autoscaling.hpa.targetCPU }}
{{- end }}
{{- end }}
{{- end }}

0 comments on commit ec253b2

Please sign in to comment.