File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,7 +27,6 @@ import (
2727 "k8s.io/apimachinery/pkg/util/validation/field"
2828 "k8s.io/utils/ptr"
2929 logf "sigs.k8s.io/controller-runtime/pkg/log"
30- "sigs.k8s.io/controller-runtime/pkg/webhook"
3130 "sigs.k8s.io/controller-runtime/pkg/webhook/admission"
3231)
3332
@@ -49,8 +48,6 @@ func SetupWatcherDefaults(defaults WatcherDefaults) {
4948 watcherlog .Info ("Watcher defaults initialized" , "defaults" , defaults )
5049}
5150
52- var _ webhook.Defaulter = & Watcher {}
53-
5451// Default implements webhook.Defaulter so a webhook will be registered for the type
5552func (r * Watcher ) Default () {
5653 watcherlog .Info ("default" , "name" , r .Name )
@@ -108,8 +105,6 @@ func (spec *WatcherSpecCore) getDeprecatedFields(old *WatcherSpecCore) []common_
108105 return deprecatedFields
109106}
110107
111- var _ webhook.Validator = & Watcher {}
112-
113108// ValidateCreate implements webhook.Validator so a webhook will be registered for the type
114109func (r * Watcher ) ValidateCreate () (admission.Warnings , error ) {
115110 watcherlog .Info ("validate create" , "name" , r .Name )
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ import (
2121 "k8s.io/apimachinery/pkg/runtime"
2222 "k8s.io/apimachinery/pkg/util/validation/field"
2323 logf "sigs.k8s.io/controller-runtime/pkg/log"
24- "sigs.k8s.io/controller-runtime/pkg/webhook"
2524 "sigs.k8s.io/controller-runtime/pkg/webhook/admission"
2625)
2726
@@ -30,8 +29,6 @@ var watcherapilog = logf.Log.WithName("watcherapi-resource")
3029
3130// TODO(user): EDIT THIS FILE! THIS IS SCAFFOLDING FOR YOU TO OWN!
3231
33- var _ webhook.Defaulter = & WatcherAPI {}
34-
3532// Default implements webhook.Defaulter so a webhook will be registered for the type
3633func (r * WatcherAPI ) Default () {
3734 watcherapilog .Info ("default" , "name" , r .Name )
@@ -41,8 +38,6 @@ func (r *WatcherAPI) Default() {
4138
4239// TODO(user): change verbs to "verbs=create;update;delete" if you want to enable deletion validation.
4340
44- var _ webhook.Validator = & WatcherAPI {}
45-
4641// ValidateCreate implements webhook.Validator so a webhook will be registered for the type
4742func (r * WatcherAPI ) ValidateCreate () (admission.Warnings , error ) {
4843 watcherapilog .Info ("validate create" , "name" , r .Name )
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ import (
2121 "k8s.io/apimachinery/pkg/runtime"
2222 "k8s.io/apimachinery/pkg/util/validation/field"
2323 logf "sigs.k8s.io/controller-runtime/pkg/log"
24- "sigs.k8s.io/controller-runtime/pkg/webhook"
2524 "sigs.k8s.io/controller-runtime/pkg/webhook/admission"
2625)
2726
@@ -30,8 +29,6 @@ var watcherapplierlog = logf.Log.WithName("watcherapplier-resource")
3029
3130// TODO(user): EDIT THIS FILE! THIS IS SCAFFOLDING FOR YOU TO OWN!
3231
33- var _ webhook.Defaulter = & WatcherApplier {}
34-
3532// Default implements webhook.Defaulter so a webhook will be registered for the type
3633func (r * WatcherApplier ) Default () {
3734 watcherapplierlog .Info ("default" , "name" , r .Name )
@@ -41,8 +38,6 @@ func (r *WatcherApplier) Default() {
4138
4239// TODO(user): change verbs to "verbs=create;update;delete" if you want to enable deletion validation.
4340
44- var _ webhook.Validator = & WatcherApplier {}
45-
4641// ValidateCreate implements webhook.Validator so a webhook will be registered for the type
4742func (r * WatcherApplier ) ValidateCreate () (admission.Warnings , error ) {
4843 watcherapplierlog .Info ("validate create" , "name" , r .Name )
Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ import (
2121 "k8s.io/apimachinery/pkg/runtime"
2222 "k8s.io/apimachinery/pkg/util/validation/field"
2323 logf "sigs.k8s.io/controller-runtime/pkg/log"
24- "sigs.k8s.io/controller-runtime/pkg/webhook"
2524 "sigs.k8s.io/controller-runtime/pkg/webhook/admission"
2625)
2726
@@ -30,8 +29,6 @@ var watcherdecisionenginelog = logf.Log.WithName("watcherdecisionengine-resource
3029
3130// TODO(user): EDIT THIS FILE! THIS IS SCAFFOLDING FOR YOU TO OWN!
3231
33- var _ webhook.Defaulter = & WatcherDecisionEngine {}
34-
3532// Default implements webhook.Defaulter so a webhook will be registered for the type
3633func (r * WatcherDecisionEngine ) Default () {
3734 watcherdecisionenginelog .Info ("default" , "name" , r .Name )
@@ -41,8 +38,6 @@ func (r *WatcherDecisionEngine) Default() {
4138
4239// TODO(user): change verbs to "verbs=create;update;delete" if you want to enable deletion validation.
4340
44- var _ webhook.Validator = & WatcherDecisionEngine {}
45-
4641// ValidateCreate implements webhook.Validator so a webhook will be registered for the type
4742func (r * WatcherDecisionEngine ) ValidateCreate () (admission.Warnings , error ) {
4843 watcherdecisionenginelog .Info ("validate create" , "name" , r .Name )
You can’t perform that action at this time.
0 commit comments