-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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 issue to don't set kustomizeconfig.yaml when Webhooks are not enable into the project #3585
Conversation
Hi @lowang-bh. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
pkg/plugins/common/kustomize/v2/scaffolds/internal/templates/config/crd/kustomization.go
Show resolved
Hide resolved
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as resolved.
This comment was marked as resolved.
Still need a new test to ensure that the project works fine when no webhooks are enable |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
/pull-kubebuilder-e2e-k8s-1-26-6 |
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
/retest |
This comment was marked as resolved.
This comment was marked as resolved.
What shall I do now? |
New changes are detected. LGTM label has been removed. |
This comment was marked as outdated.
This comment was marked as outdated.
… and projects without webhooks At present, we scaffold config/crd/patches, kustomizations, and CA injections for every CRD, irrespective of whether webhooks are enabled in the project or not. However, these configurations are only relevant and valid if the project has webhooks. Consequently, for projects without webhooks, this leads to failures as documented in kubebuilder pull request kubernetes-sigs#3585. To address this, we are now introducing a test to ensure that projects without enabled webhooks function correctly and as anticipated. Signed-off-by: Camila Macedo <[email protected]> Co-authored-by: lowang-bh <[email protected]> fix: just generate crd webhooks patches and ca injestions when webhooks are created for those
… and projects without webhooks At present, we scaffold config/crd/patches, kustomizations, and CA injections for every CRD, irrespective of whether webhooks are enabled in the project or not. However, these configurations are only relevant and valid if the project has webhooks. Consequently, for projects without webhooks, this leads to failures as documented in kubebuilder pull request kubernetes-sigs#3585. To address this, we are now introducing a test to ensure that projects without enabled webhooks function correctly and as anticipated. Signed-off-by: Camila Macedo <[email protected]> Co-authored-by: lowang-bh <[email protected]> fix: just generate crd webhooks patches and ca injestions when webhooks are created for those
… and projects without webhooks At present, we scaffold config/crd/patches, kustomizations, and CA injections for every CRD, irrespective of whether webhooks are enabled in the project or not. However, these configurations are only relevant and valid if the project has webhooks. Consequently, for projects without webhooks, this leads to failures as documented in kubebuilder pull request kubernetes-sigs#3585. To address this, we are now introducing a test to ensure that projects without enabled webhooks function correctly and as anticipated. Signed-off-by: Camila Macedo <[email protected]> Co-authored-by: lowang-bh <[email protected]>
# configurations: | ||
# - kustomizeconfig.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.
# configurations: | |
# - kustomizeconfig.yaml | |
#configurations: | |
#- kustomizeconfig.yaml |
We cannot have the space
Also, we should automatically uncomment this one when a webhook is scaffold.
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.
Hi @lowang-bh,
By doing the e2e tests I could check that it would still missing few things
So, I used your PR to give your the credit as well and keep you as co-author
See; #3647
Can we close this one in favor of #3647
Could you please help in the review of #3647 for we move forward and get that one merged.
/approved cancel
/lgtm cancel
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: lowang-bh The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
… and projects without webhooks At present, we scaffold config/crd/patches, kustomizations, and CA injections for every CRD, irrespective of whether webhooks are enabled in the project or not. However, these configurations are only relevant and valid if the project has webhooks. Consequently, for projects without webhooks, this leads to failures as documented in kubebuilder pull request kubernetes-sigs#3585. To address this, we are now introducing a test to ensure that projects without enabled webhooks function correctly and as anticipated. Signed-off-by: Camila Macedo <[email protected]> Co-authored-by: lowang-bh <[email protected]>
… and projects without webhooks At present, we scaffold config/crd/patches, kustomizations, and CA injections for every CRD, irrespective of whether webhooks are enabled in the project or not. However, these configurations are only relevant and valid if the project has webhooks. Consequently, for projects without webhooks, this leads to failures as documented in kubebuilder pull request kubernetes-sigs#3585. To address this, we are now introducing a test to ensure that projects without enabled webhooks function correctly and as anticipated. Signed-off-by: Camila Macedo <[email protected]> Co-authored-by: lowang-bh <[email protected]>
Description
Fix error in the layout when webhooks are not enable in the project.
Motivation
Fixes #3367