Skip to content
This repository was archived by the owner on May 3, 2022. It is now read-only.

Commit ae30deb

Browse files
author
Titouan BION
authored
Extend WebhookConfigurations to any apiVersion (#401)
We'd rather fail close on validation that an object unvalidated reach the cluster.
1 parent 033806d commit ae30deb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

cmd/shipperctl/configurator/cluster.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -432,7 +432,7 @@ func (c *Cluster) CreateOrUpdateValidatingWebhookConfiguration(caBundle []byte,
432432
},
433433
Rule: admissionregistrationv1beta1.Rule{
434434
APIGroups: []string{shipper.SchemeGroupVersion.Group},
435-
APIVersions: []string{shipper.SchemeGroupVersion.Version},
435+
APIVersions: []string{"*"},
436436
Resources: []string{"*"},
437437
},
438438
},

cmd/shipperctl/configurator/cluster_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ func (f *fixture) newValidatingWebhookConfiguration(caBundle []byte, namespace s
175175
Operations: operations,
176176
Rule: admissionregistrationv1beta1.Rule{
177177
APIGroups: []string{shipper.SchemeGroupVersion.Group},
178-
APIVersions: []string{shipper.SchemeGroupVersion.Version},
178+
APIVersions: []string{"*"},
179179
Resources: []string{"*"},
180180
},
181181
},

0 commit comments

Comments
 (0)