Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix webhook resource api version #136

Merged
merged 1 commit into from
Oct 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions api/v1beta1/flinkcluster_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ This marker is responsible for generating a mutating webhook manifest.
The meaning of each marker can be found [here](/reference/markers/webhook.md).
*/

// +kubebuilder:webhook:path=/mutate-flinkoperator-k8s-io-v1beta1-flinkcluster,admissionReviewVersions=v1,sideEffects=None,mutating=true,failurePolicy=fail,groups=flinkoperator.k8s.io,resources=flinkclusters,verbs=create;update,versions=v1,name=mflinkcluster.flinkoperator.k8s.io
// +kubebuilder:webhook:path=/mutate-flinkoperator-k8s-io-v1beta1-flinkcluster,admissionReviewVersions=v1,sideEffects=None,mutating=true,failurePolicy=fail,groups=flinkoperator.k8s.io,resources=flinkclusters,verbs=create;update,versions=v1beta1,name=mflinkcluster.flinkoperator.k8s.io

/*
We use the `webhook.Defaulter` interface to set defaults to our CRD.
Expand All @@ -63,7 +63,7 @@ func (cluster *FlinkCluster) Default() {
This marker is responsible for generating a validating webhook manifest.
*/

// +kubebuilder:webhook:path=/validate-flinkoperator-k8s-io-v1beta1-flinkcluster,admissionReviewVersions=v1,sideEffects=None,mutating=false,failurePolicy=fail,groups=flinkoperator.k8s.io,resources=flinkclusters,verbs=create;update,versions=v1,name=vflinkcluster.flinkoperator.k8s.io
// +kubebuilder:webhook:path=/validate-flinkoperator-k8s-io-v1beta1-flinkcluster,admissionReviewVersions=v1,sideEffects=None,mutating=false,failurePolicy=fail,groups=flinkoperator.k8s.io,resources=flinkclusters,verbs=create;update,versions=v1beta1,name=vflinkcluster.flinkoperator.k8s.io

var _ webhook.Validator = &FlinkCluster{}
var validator = Validator{}
Expand Down
4 changes: 2 additions & 2 deletions config/webhook/manifests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ webhooks:
- apiGroups:
- flinkoperator.k8s.io
apiVersions:
- v1
- v1beta1
operations:
- CREATE
- UPDATE
Expand Down Expand Up @@ -47,7 +47,7 @@ webhooks:
- apiGroups:
- flinkoperator.k8s.io
apiVersions:
- v1
- v1beta1
operations:
- CREATE
- UPDATE
Expand Down