Skip to content

Conversation

dmvolod
Copy link
Member

@dmvolod dmvolod commented Feb 20, 2025

What this PR does / why we need it:
This allows to disable core (or any others in the future) provider enabled by default

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 #11854

/area devtools

@k8s-ci-robot k8s-ci-robot added area/devtools Issues or PRs related to devtools cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Feb 20, 2025
Comment on lines 88 to 89
**disable_providers** (Array[]String, default=[]): A list of the providers to disable. By default, the `core` provider is always installed. You can also disable it.

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 instead just add a bool disable_core_provider. All others are already opt-in.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, sure, it was my original approach, but tried to do more flexible.
Ok, let's revert it.

Copy link
Member

Choose a reason for hiding this comment

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

I also wasn't sure, but I think Christian's suggestion is fine. I don't foresee us adding any other default providers

Is it also possible to have enable_core_provider and default it to true?

Copy link
Member Author

@dmvolod dmvolod Feb 20, 2025

Choose a reason for hiding this comment

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

Fixed.

Added disable_core_provider option which is False by default.

Copy link
Member

Choose a reason for hiding this comment

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

I would just flip it around and call it enable_core_provider and default True. We already have enable_providers + double negation is never great

Copy link
Member Author

Choose a reason for hiding this comment

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

Ok, switched to enable_core_provider option which allows to disable it.

@dmvolod dmvolod force-pushed the disable-core-in-tiltfile-option branch from 748b5ef to a015615 Compare February 20, 2025 10:02
@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Feb 20, 2025
@dmvolod dmvolod changed the title 🌱 Add disable_providers option support in tilt-settings.yaml|json file 🌱 Add disable_core_provider option support in tilt-settings.yaml|json file Feb 20, 2025
@dmvolod dmvolod force-pushed the disable-core-in-tiltfile-option branch from a015615 to 03a7288 Compare February 20, 2025 10:21
@dmvolod dmvolod changed the title 🌱 Add disable_core_provider option support in tilt-settings.yaml|json file 🌱 Add enable_core_provider option support in tilt-settings.yaml|json file Feb 20, 2025
@dmvolod dmvolod force-pushed the disable-core-in-tiltfile-option branch from 03a7288 to 5ce8edb Compare February 20, 2025 10:37
@sbueringer
Copy link
Member

Thx!

/lgtm

Would be good if someone can do quick manual tests with/without the setting before we merge this PR

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 20, 2025
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 47834b1f5a133661ef087d016a84868a57b091c3

Copy link
Member

@chrischdi chrischdi left a comment

Choose a reason for hiding this comment

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

Tested all three:

  • enable_core_provider: true
  • enable_core_provider: false
  • # enable_core_provider: false

/approve

@chrischdi chrischdi added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 20, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by: chrischdi

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

@k8s-ci-robot k8s-ci-robot merged commit 1c864e0 into kubernetes-sigs:main Feb 20, 2025
16 checks passed
@k8s-ci-robot k8s-ci-robot added this to the v1.10 milestone Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. area/devtools Issues or PRs related to devtools cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reuse common Tiltfile approach for Cluster API Operator

4 participants