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]: Add listener based on the machine label and listener label #2155

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

Conversation

Shilpa-Gokul
Copy link
Contributor

What this PR does / why we need it:
This PR is not ready to review yet.
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 #1678

Special notes for your reviewer:

/area provider/ibmcloud

  1. Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

Release note:


@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. area/provider/ibmcloud Issues or PRs related to ibmcloud provider cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jan 29, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Shilpa-Gokul
Once this PR has been reviewed and has the lgtm label, please assign prajyot-parab for approval. For more information see the 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

@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jan 29, 2025
@k8s-ci-robot
Copy link
Contributor

Hi @Shilpa-Gokul. 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 /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

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

@k8s-ci-robot k8s-ci-robot added the size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. label Jan 29, 2025
Copy link

netlify bot commented Jan 29, 2025

Deploy Preview for kubernetes-sigs-cluster-api-ibmcloud ready!

Name Link
🔨 Latest commit aac912c
🔍 Latest deploy log https://app.netlify.com/sites/kubernetes-sigs-cluster-api-ibmcloud/deploys/6799f9f0b4952b0008dd7895
😎 Deploy Preview https://deploy-preview-2155--kubernetes-sigs-cluster-api-ibmcloud.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@@ -127,6 +127,8 @@ type AdditionalListenerSpec struct {
// Will default to TCP protocol if not specified.
// +optional
Protocol *VPCLoadBalancerListenerProtocol `json:"protocol,omitempty"`

Selector metav1.LabelSelector `json:"selector"`
Copy link
Member

Choose a reason for hiding this comment

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

  • This needs to be optional and also omitempty
  • Is there a scope for multiple selector? @Karthik-K-N
  • what will happen if someone changes this field? are we allowing this field to be changed? if not - can we block it?

Copy link
Contributor

Choose a reason for hiding this comment

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

what will happen if someone changes this field?

I think to start with we can make this field immutable? so we can block the changes to the field.

Is there a scope for multiple selector?

You mean like configure the listener to multiple machine like Port 22 for machine-1 and machine-2

There are two options

  1. Add 2 listener with same port but with different selector
  2. Allow label to have multiple machine separated by comma(,) and add support for this in controller
    like
    infrastructure.cluster.x-k8s.io/machine-name: machine1, machine2

Copy link
Member

Choose a reason for hiding this comment

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

my bad, this make sense.. may be its worth adding more examples so that it becomes clear for the consumers.
I find this reference useful - https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/

@mkumatag
Copy link
Member

@Shilpa-Gokul its worth writing a design doc with more examples, lets do that before this PR.

I like the way it is written here - #2139 for one of the work.

@Karthik-K-N
Copy link
Contributor

@Shilpa-Gokul its worth writing a design doc with more examples, lets do that before this PR.

I like the way it is written here - #2139 for one of the work.

Yes, We have already planned to do so, With some diagrams and examples, That would become easier for review and to see if there is any better approach as well, This is also one of the reasons for keeping this as WIP and also adding UT with only happy paths.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/provider/ibmcloud Issues or PRs related to ibmcloud provider cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add way to specify only bootstrap VM should be added to listener pool
4 participants