| {{- $autoscalingv2 := .Capabilities.APIVersions.Has "autoscaling/v2" -}} |
| {{- if .Values.gateway.autoscaling.enabled }} |
| apiVersion: autoscaling/v2 |
| apiVersion: autoscaling/v2beta1 |
| kind: HorizontalPodAutoscaler |
| name: {{ include "loki.gatewayFullname" . }} |
| {{- include "loki.gatewayLabels" . | nindent 4 }} |
| name: {{ include "loki.gatewayFullname" . }} |
| minReplicas: {{ .Values.gateway.autoscaling.minReplicas }} |
| maxReplicas: {{ .Values.gateway.autoscaling.maxReplicas }} |
| {{- with .Values.gateway.autoscaling.targetMemoryUtilizationPercentage }} |
| averageUtilization: {{ . }} |
| targetAverageUtilization: {{ . }} |
| {{- with .Values.gateway.autoscaling.targetCPUUtilizationPercentage }} |
| averageUtilization: {{ . }} |
| targetAverageUtilization: {{ . }} |