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

🌱 [wip] bump controller-gen and regenerate manifests to optimize RBAC #10612

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

chrischdi
Copy link
Member

@chrischdi chrischdi commented May 14, 2024

uses controller-gen from kubernetes-sigs/controller-tools#937

What this PR does / why we need it:

Bumps controller-gen to commit kubernetes-sigs/controller-tools@ed2fbe2 .

This includes:

Which deduplicates rbac stuff and makes the roles better readable.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #

Area example:
/area dependency

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-area PR is missing an area label labels May 14, 2024
@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label May 14, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please ask for approval from chrischdi. For more information see the Kubernetes Code Review Process.

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link
Member

@sbueringer sbueringer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest to drop the +required from v1alpha3 + v1alpha4 conditions to get rid of the change in the CRDs. Type are internal now anyway

@@ -1000,6 +1000,7 @@ spec:
can be useful (see .node.status.conditions), the ability to deconflict is important.
type: string
required:
- lastTransitionTime
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's talk about this with Fabrizio. I think this happens because CT now supports the upstream +required marker. That was somehow used on v1alpha3 & v1alpha4 (with v1beta1 we dropped omitempty on this field so it became required per default)

Just have to decide what we want to do. Shouldn't matter much as these types are now only used for conversion and not served anymore

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is only making explicit in the OpenAPI spec the fact that this field is required (it is not a pointer, it doesn't have omitempty), then I'm ok with this change

@sbueringer
Copy link
Member

sbueringer commented May 14, 2024

@chrischdi I would appreciate if we can merge this PR before the other CAPI PR. Because I already verified that all the changes in this PR are correct (apart from the last nit regarding lastTransitionTime + rebase on top of CT main)

@chrischdi
Copy link
Member Author

Rebased to latest master commit for controller-tools.

@chrischdi
Copy link
Member Author

/test help

@k8s-ci-robot
Copy link
Contributor

@chrischdi: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test pull-cluster-api-build-main
  • /test pull-cluster-api-e2e-blocking-main
  • /test pull-cluster-api-e2e-conformance-ci-latest-main
  • /test pull-cluster-api-e2e-conformance-main
  • /test pull-cluster-api-e2e-main
  • /test pull-cluster-api-e2e-mink8s-main
  • /test pull-cluster-api-e2e-upgrade-1-30-1-31-main
  • /test pull-cluster-api-test-main
  • /test pull-cluster-api-test-mink8s-main
  • /test pull-cluster-api-verify-main

The following commands are available to trigger optional jobs:

  • /test pull-cluster-api-apidiff-main

Use /test all to run the following jobs that were automatically triggered:

  • pull-cluster-api-apidiff-main
  • pull-cluster-api-build-main
  • pull-cluster-api-e2e-blocking-main
  • pull-cluster-api-test-main
  • pull-cluster-api-verify-main

In response to this:

/test help

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-sigs/prow repository.

@chrischdi
Copy link
Member Author

/test pull-cluster-api-e2e-main

@chrischdi chrischdi closed this May 14, 2024
@chrischdi chrischdi reopened this May 14, 2024
@chrischdi
Copy link
Member Author

One enter too much which closed it...

/test pull-cluster-api-e2e-main

@chrischdi chrischdi changed the title [WIP] 🌱 bump controller-gen and regenerate manifests to optimize RBAC 🌱 bump controller-gen and regenerate manifests to optimize RBAC May 14, 2024
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 14, 2024
@k8s-ci-robot
Copy link
Contributor

@chrischdi: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-cluster-api-e2e-main 73d968d link true /test pull-cluster-api-e2e-main
pull-cluster-api-e2e-blocking-main 73d968d link true /test pull-cluster-api-e2e-blocking-main

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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-sigs/prow repository. I understand the commands that are listed here.

@chrischdi chrischdi changed the title 🌱 bump controller-gen and regenerate manifests to optimize RBAC 🌱 [wip] bump controller-gen and regenerate manifests to optimize RBAC May 14, 2024
@chrischdi
Copy link
Member Author

/area dependency

/hold

This should wait for v0.16 of controller-tools (~ August)

@k8s-ci-robot k8s-ci-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. area/dependency Issues or PRs related to dependency changes needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed do-not-merge/needs-area PR is missing an area label labels May 14, 2024
@k8s-ci-robot
Copy link
Contributor

PR needs rebase.

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-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dependency Issues or PRs related to dependency changes cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants