File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
deploy/cert-manager-sync/templates Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change 11{{- if .Values.autoscaling.enabled }}
2+ {{- if .Capabilities.APIVersions.Has "autoscaling/v2" }}
3+ apiVersion : autoscaling/v2
4+ {{- else if .Capabilities.APIVersions.Has "autoscaling/v2beta2" }}
5+ apiVersion : autoscaling/v2beta2
6+ {{- else }}
27apiVersion : autoscaling/v2beta1
8+ {{- end }}
39kind : HorizontalPodAutoscaler
410metadata :
511 name : {{ include "cert-manager-sync.fullname" . }}
@@ -17,12 +23,24 @@ spec:
1723 - type : Resource
1824 resource :
1925 name : cpu
26+ {{- if or (.Capabilities.APIVersions.Has "autoscaling/v2") (.Capabilities.APIVersions.Has "autoscaling/v2beta2") }}
27+ target :
28+ type : Utilization
29+ averageUtilization : {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
30+ {{- else }}
2031 targetAverageUtilization : {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
32+ {{- end }}
2133 {{- end }}
2234 {{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
2335 - type : Resource
2436 resource :
2537 name : memory
38+ {{- if or (.Capabilities.APIVersions.Has "autoscaling/v2") (.Capabilities.APIVersions.Has "autoscaling/v2beta2") }}
39+ target :
40+ type : Utilization
41+ averageUtilization : {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
42+ {{- else }}
2643 targetAverageUtilization : {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
44+ {{- end }}
2745 {{- end }}
2846{{- end }}
You can’t perform that action at this time.
0 commit comments