Skip to content

Commit

Permalink
in webhook add match condition by scheduler name filter pod resources
Browse files Browse the repository at this point in the history
Signed-off-by: rongfu.leng <[email protected]>
  • Loading branch information
lengrongfu committed Sep 26, 2024
1 parent 18d45c0 commit 917b858
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions installer/helm/chart/volcano/templates/webhooks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ webhooks:
namespace: {{ .Release.Namespace }}
path: /pods/mutate
port: 443
failurePolicy: Fail
failurePolicy: Ignore
matchPolicy: Equivalent
name: mutatepod.volcano.sh
namespaceSelector:
Expand All @@ -33,6 +33,9 @@ webhooks:
{{- end }}
objectSelector: {}
reinvocationPolicy: Never
matchConditions:
- expression: object.spec.schedulerName == 'volcano'
name: scheduler-name-match
rules:
- apiGroups:
- ""
Expand Down Expand Up @@ -262,7 +265,7 @@ webhooks:
namespace: {{ .Release.Namespace }}
path: /pods/validate
port: 443
failurePolicy: Fail
failurePolicy: Ignore
matchPolicy: Equivalent
name: validatepod.volcano.sh
namespaceSelector:
Expand All @@ -276,6 +279,9 @@ webhooks:
{{- toYaml .Values.custom.webhooks_namespace_selector_expressions | nindent 8 }}
{{- end }}
objectSelector: {}
matchConditions:
- expression: object.spec.schedulerName == 'volcano'
name: scheduler-name-match
rules:
- apiGroups:
- ""
Expand Down

0 comments on commit 917b858

Please sign in to comment.