File tree Expand file tree Collapse file tree 3 files changed +30
-14
lines changed Expand file tree Collapse file tree 3 files changed +30
-14
lines changed Original file line number Diff line number Diff line change @@ -234,3 +234,18 @@ requests:
234234 false
235235 { {- end } }
236236{ {- end } }
237+
238+ { {- define " wiz-admission-controller.hpaBehavior" -} }
239+ { {- if hasKey .Values.hpa " behavior" } }
240+ { {- toYaml .Values.hpa.behavior } }
241+ { {- else -} }
242+ scaleUp:
243+ stabilizationWindowSeconds: 300
244+ scaleDown:
245+ stabilizationWindowSeconds: 300
246+ policies:
247+ - type: Pods
248+ value: 1
249+ periodSeconds: 300
250+ { {- end -} }
251+ { {- end -} }
Original file line number Diff line number Diff line change 3535 {{- with .Values.hpa.customMetrics }}
3636 {{- toYaml . | nindent 4 }}
3737 {{- end }}
38- {{- if hasKey .Values.hpa "behavior" }}
39- behavior :
40- {{- toYaml .Values.hpa.behavior | nindent 4 }}
41- {{- end }}
38+ behavior : {{ include "wiz-admission-controller.hpaBehavior" . | nindent 4 }}
4239---
4340{{- end }}
4441{{ if .Values.kubernetesAuditLogsWebhook.enabled -}}
7673 {{- with .Values.hpa.customMetrics }}
7774 {{- toYaml . | nindent 4 }}
7875 {{- end }}
79- {{- if hasKey .Values.hpa "behavior" }}
80- behavior :
81- {{- toYaml .Values.hpa.behavior | nindent 4 }}
82- {{- end }}
76+ behavior : {{ include "wiz-admission-controller.hpaBehavior" . | nindent 4 }}
8377{{- end }}
8478{{- end }}
Original file line number Diff line number Diff line change @@ -437,19 +437,26 @@ probes: # Probes config for the container
437437# Horizontal Pod Autoscaling.
438438# Prerequisites: metrics-server installed on the cluster:
439439# https://github.com/kubernetes-sigs/metrics-server
440- #
441440hpa :
442441 enabled : false
443442 minReplicas : 2
444443 maxReplicas : 5
445444 enableCPU : true
446- targetCPUUtilizationPercentage : 50
445+ targetCPUUtilizationPercentage : 80
447446 enableMemory : false
448- targetMemoryUtilizationPercentage : 50
447+ targetMemoryUtilizationPercentage : 80
449448 customMetrics : []
450- # Uncomment to customize the behavior.
451- # If not set, the default HPAScalingRules for scale up and scale down are used.
452- # behavior: {}
449+ # Uncomment the `behavior` section below to specify custom scaling policies and behavior.
450+ # If left blank, the following default settings are applied:
451+ # behavior:
452+ # scaleUp:
453+ # stabilizationWindowSeconds: 300
454+ # scaleDown:
455+ # stabilizationWindowSeconds: 300
456+ # policies:
457+ # - type: Pods
458+ # value: 1
459+ # periodSeconds: 300
453460
454461# Global values to override chart values.
455462global :
You can’t perform that action at this time.
0 commit comments