Skip to content

Commit d1a22e0

Browse files
author
Shreya027
authored
Enable setting custom objectSelector for webhook (#2407)
* Enable setting custom objectSelector for webhook #650 * Add formatting changes * Add webhook changes to README * Read update suggestion * Update READ table header to original
1 parent 2f525fd commit d1a22e0

File tree

4 files changed

+20
-1
lines changed

4 files changed

+20
-1
lines changed

helm/aws-load-balancer-controller/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
apiVersion: v2
22
name: aws-load-balancer-controller
33
description: AWS Load Balancer Controller Helm chart for Kubernetes
4-
version: 1.3.3
4+
version: 1.3.4
55
appVersion: v2.3.1
66
home: https://github.com/aws/eks-charts
77
icon: https://raw.githubusercontent.com/aws/eks-charts/master/docs/logo/aws.png

helm/aws-load-balancer-controller/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,3 +214,5 @@ The default values set by the application itself can be confirmed [here](https:/
214214
| `enableBackendSecurityGroup` | If enabled, controller uses shared security group for backend traffic | `true` |
215215
| `backendSecurityGroup` | Backend security group to use instead of auto created one if the feature is enabled | `` |
216216
| `disableRestrictedSecurityGroupRules` | If disabled, controller will not specify port range restriction in the backend security group rules | `false` |
217+
| `objectSelector.matchExpressions` | Webhook configuration to select specific pods by specifying the expression to be matched | None |
218+
| `objectSelector.matchLabels` | Webhook configuration to select specific pods by specifying the key value label pair to be matched | None |

helm/aws-load-balancer-controller/templates/webhook.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,13 @@ webhooks:
3737
operator: NotIn
3838
values:
3939
- {{ include "aws-load-balancer-controller.name" . }}
40+
{{- if .Values.objectSelector.matchExpressions }}
41+
{{- toYaml .Values.objectSelector.matchExpressions | nindent 4 }}
42+
{{- end }}
43+
{{- if .Values.objectSelector.matchLabels }}
44+
matchLabels:
45+
{{- toYaml .Values.objectSelector.matchLabels | nindent 6 }}
46+
{{- end }}
4047
rules:
4148
- apiGroups:
4249
- ""

helm/aws-load-balancer-controller/values.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -232,3 +232,13 @@ backendSecurityGroup:
232232

233233
# disableRestrictedSecurityGroupRules specifies whether to disable creating port-range restricted security group rules for traffic
234234
disableRestrictedSecurityGroupRules:
235+
236+
# objectSelector for webhook
237+
objectSelector:
238+
matchExpressions:
239+
# - key: <key>
240+
# operator: <operator>
241+
# values:
242+
# - <value>
243+
matchLabels:
244+
# key: value

0 commit comments

Comments
 (0)