Skip to content

Commit

Permalink
Add configurable failurePolicy for injector's webhook
Browse files Browse the repository at this point in the history
Fixes #399
  • Loading branch information
orirawlings committed Oct 12, 2020
1 parent 5242cfe commit 8fbf1ae
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions templates/injector-mutating-webhook.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,7 @@ webhooks:
namespaceSelector:
{{ toYaml .Values.injector.namespaceSelector | indent 6}}
{{ end }}
{{- with .Values.injector.failurePolicy }}
failurePolicy: {{.}}
{{ end }}
{{ end }}
6 changes: 6 additions & 0 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,12 @@ injector:
# sidecar-injector: enabled
namespaceSelector: {}

# Configures failurePolicy of the webhook. By default webhook failures are ignored.
# To block pod creation while webhook is unavailable, set the policy to `Fail` below.
# See https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#failure-policy
#
# failurePolcy: Fail

certs:
# secretName is the name of the secret that has the TLS certificate and
# private key to serve the injector webhook. If this is null, then the
Expand Down

0 comments on commit 8fbf1ae

Please sign in to comment.