diff --git a/charts/nginx-ingress/README.md b/charts/nginx-ingress/README.md index f35a57fcaa..da6e2a1418 100644 --- a/charts/nginx-ingress/README.md +++ b/charts/nginx-ingress/README.md @@ -441,6 +441,7 @@ The following tables lists the configurable parameters of the NGINX Ingress Cont |`controller.minReadySeconds` | Specifies the minimum number of seconds for which a newly created Pod should be ready without any of its containers crashing, for it to be considered available. [docs](https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#min-ready-seconds) | 0 | |`controller.autoscaling.enabled` | Enables HorizontalPodAutoscaling. | false | |`controller.autoscaling.annotations` | The annotations of the Ingress Controller HorizontalPodAutoscaler. | {} | +|`controller.autoscaling.behavior` | Behavior configuration for the HPA. | {} | |`controller.autoscaling.minReplicas` | Minimum number of replicas for the HPA. | 1 | |`controller.autoscaling.maxReplicas` | Maximum number of replicas for the HPA. | 3 | |`controller.autoscaling.targetCPUUtilizationPercentage` | The target CPU utilization percentage. | 50 | diff --git a/charts/nginx-ingress/templates/controller-hpa.yaml b/charts/nginx-ingress/templates/controller-hpa.yaml index b8691648e9..971aca90d3 100644 --- a/charts/nginx-ingress/templates/controller-hpa.yaml +++ b/charts/nginx-ingress/templates/controller-hpa.yaml @@ -17,6 +17,10 @@ spec: name: {{ include "nginx-ingress.controller.fullname" . }} minReplicas: {{ .Values.controller.autoscaling.minReplicas }} maxReplicas: {{ .Values.controller.autoscaling.maxReplicas }} +{{- if .Values.controller.autoscaling.behavior }} + behavior: +{{ toYaml .Values.controller.autoscaling.behavior | indent 4 }} +{{- end }} metrics: {{- if .Values.controller.autoscaling.targetMemoryUtilizationPercentage }} - type: Resource diff --git a/charts/nginx-ingress/values.yaml b/charts/nginx-ingress/values.yaml index 13ed1e857c..9dd9a9a021 100644 --- a/charts/nginx-ingress/values.yaml +++ b/charts/nginx-ingress/values.yaml @@ -153,6 +153,8 @@ controller: targetCPUUtilizationPercentage: 50 ## The target memory utilization percentage. targetMemoryUtilizationPercentage: 50 + ## Custom behavior policies + behavior: {} ## The resources of the Ingress Controller pods. resources: