-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
🐛 (kustomize/v2, go/v4): Fix incorrect generation of manifests under config/crd/patches. Previously, the /convert service patch was being generated for all webhooks instead of only for those with --conversion enabled. #4280
🐛 (kustomize/v2, go/v4): Fix incorrect generation of manifests under config/crd/patches. Previously, the /convert service patch was being generated for all webhooks instead of only for those with --conversion enabled. #4280
Conversation
b25e97e
to
cc357ce
Compare
This PR addresses a very small but blocking bug fix, which impacts other critical PRs, such as #4280. |
- path: patches/webhook_in_crew_captains.yaml | ||
- path: patches/webhook_in_ship_destroyers.yaml | ||
- path: patches/webhook_in_ship_cruisers.yaml | ||
- path: patches/webhook_in_example.com_memcacheds.yaml | ||
- path: patches/webhook_in_example.com_wordpresses.yaml |
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.
@camilamacedo86 is there any specific reason for keeping this webhook patch, here?
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.
No, the goal of this PR is to remove these patches. They should never be added or scaffolded, as they are only valid for a specific type of webhook (conversion). The issue is that they have been incorrectly generated for all webhooks, not just conversion webhooks.
For non-conversion webhooks, CA injection is already configured via config/default/kustomize (and conversion webhooks will be handled similarly in a follow-up PR).
This bug is a remnant from the legacy layout when older versions of Kustomize, which supported vars, were used.
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.
Looks good to me.
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: camilamacedo86, TAM360 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…eate webhook --conversion Ensure config/crd/patches are only generated for CRDs that were created using kubebuilder create webhook --conversion, as these patches are specific to conversion configuration and not needed for other CRDs.
cc357ce
to
01ff68b
Compare
Ensure config/crd/patches are only generated for CRDs that were created using kubebuilder create webhook --conversion, as these patches are specific to conversion configuration and not needed for other CRDs.