From 879b6d76a6bb87632a14da4be77ba230f5f4498d Mon Sep 17 00:00:00 2001 From: Matt Miller Date: Wed, 22 Oct 2025 11:31:24 -0400 Subject: [PATCH 1/2] feat: add maxTargetsPerTarget group flag to helm chart --- helm/aws-load-balancer-controller/templates/deployment.yaml | 3 +++ helm/aws-load-balancer-controller/values.yaml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/helm/aws-load-balancer-controller/templates/deployment.yaml b/helm/aws-load-balancer-controller/templates/deployment.yaml index 42e6db5188..0574a77667 100644 --- a/helm/aws-load-balancer-controller/templates/deployment.yaml +++ b/helm/aws-load-balancer-controller/templates/deployment.yaml @@ -181,6 +181,9 @@ spec: {{- if .Values.vpcTags }} - --aws-vpc-tags={{ include "aws-load-balancer-controller.convertMapToCsv" .Values.vpcTags | trimSuffix "," }} {{- end }} + {{- if .Values.maxTargetsPerTargetGroup }} + - --max-targets-per-target-group={{ .Values.maxTargetsPerTargetGroup }} + {{- end }} {{- if or .Values.env .Values.envSecretName }} env: {{- if .Values.env}} diff --git a/helm/aws-load-balancer-controller/values.yaml b/helm/aws-load-balancer-controller/values.yaml index 4cc86f0ac1..c1d2be6619 100644 --- a/helm/aws-load-balancer-controller/values.yaml +++ b/helm/aws-load-balancer-controller/values.yaml @@ -371,6 +371,9 @@ backendSecurityGroup: # disableRestrictedSecurityGroupRules specifies whether to disable creating port-range restricted security group rules for traffic disableRestrictedSecurityGroupRules: +# maxTargetsPerTargetGroup specifies the maximum number of targets that the controller will attempt to add to a given ELB instance +maxTargetsPerTargetGroup: + # controllerConfig specifies controller configuration controllerConfig: # featureGates set of key: value pairs that describe AWS load balance controller features From 090661021d3e50c2b628c5c4e20ba9656de988c6 Mon Sep 17 00:00:00 2001 From: Matt Miller Date: Wed, 22 Oct 2025 11:41:59 -0400 Subject: [PATCH 2/2] update readme --- helm/aws-load-balancer-controller/README.md | 1 + helm/aws-load-balancer-controller/test.yaml | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/helm/aws-load-balancer-controller/README.md b/helm/aws-load-balancer-controller/README.md index 6da919857e..8ccf0c3362 100644 --- a/helm/aws-load-balancer-controller/README.md +++ b/helm/aws-load-balancer-controller/README.md @@ -265,6 +265,7 @@ The default values set by the application itself can be confirmed [here](https:/ | `enableManageBackendSecurityGroupRules` | If enabled, controller will manage security group rules | `false` | | `backendSecurityGroup` | Backend security group to use instead of auto created one if the feature is enabled | `` | | `disableRestrictedSecurityGroupRules` | If disabled, controller will not specify port range restriction in the backend security group rules | `false` | +| `maxTargetsPerTargetGroup` | Specifies the maximum number of targets that the controller will attempt to add to a given ELB instance. If unset, no limits are applied. | `0` | | `objectSelector.matchExpressions` | Webhook configuration to select specific pods by specifying the expression to be matched | None | | `objectSelector.matchLabels` | Webhook configuration to select specific pods by specifying the key value label pair to be matched | None | | `serviceMonitor.enabled` | Specifies whether a service monitor should be created, requires the ServiceMonitor CRD to be installed | `false` | diff --git a/helm/aws-load-balancer-controller/test.yaml b/helm/aws-load-balancer-controller/test.yaml index ae96b151d8..76eada796e 100644 --- a/helm/aws-load-balancer-controller/test.yaml +++ b/helm/aws-load-balancer-controller/test.yaml @@ -292,6 +292,9 @@ backendSecurityGroup: # disableRestrictedSecurityGroupRules specifies whether to disable creating port-range restricted security group rules for traffic disableRestrictedSecurityGroupRules: +# maxTargetsPerTargetGroup specifies the maximum number of targets that the controller will attempt to add to a given ELB instance +maxTargetsPerTargetGroup: + # controllerConfig specifies controller configuration controllerConfig: # featureGates set of key: value pairs that describe AWS load balance controller features @@ -356,4 +359,4 @@ serviceMutatorWebhookConfig: podMutatorWebhookConfig: # whether or not to fail the pod creation if the webhook fails - failurePolicy: Ignore \ No newline at end of file + failurePolicy: Ignore