-
Notifications
You must be signed in to change notification settings - Fork 127
[Draft] Validation Webhook for splunk-operator #1664
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
base: develop
Are you sure you want to change the base?
Conversation
Pull Request Test Coverage Report for Build 21135429752Details
💛 - Coveralls |
api/v4/webhook.go
Outdated
| @@ -0,0 +1,60 @@ | |||
| /* | |||
| Copyright (c) 2018-2022 Splunk Inc. All rights reserved. | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it requires updating to 2026 included
api/v4/webhook.go
Outdated
| type SplunkValidator struct{} | ||
|
|
||
| // SetupWebhookWithManager registers the centralized webhook with the manager | ||
| func SetupWebhookWithManager(mgr ctrl.Manager) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need an error return at all if we always return nil
cmd/main.go
Outdated
| } | ||
|
|
||
| // Setup centralized validation webhook for all CRDs | ||
| if err = enterpriseApi.SetupWebhookWithManager(mgr); err != nil { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And if we always return nil in SetupWebhookWithManager, then this if is not required
Description
This PR aims to add validation webhook for splunk-operator. This includes every CRD that operator consist of.
Key Changes
[DRAFT]
Testing and Verification
N/A
Related Issues
N/A
PR Checklist