-
Notifications
You must be signed in to change notification settings - Fork 159
Allow disabling particular driver services #449
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
Allow disabling particular driver services #449
Conversation
Welcome @rfranzke! |
Hi @rfranzke. 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. |
/assign @msau42 |
/ok-to-test |
55e14b8
to
94cdf36
Compare
/retest |
@davidz627 @msau42 @jingxu97 any feedback for this PR? |
why have Another nit is that (correct me if im wrong) but I don't think Its been a while since I've looked at this code but it looks like your changes to pkg/gce-cloud-provider/compute/gce.go and renaming gceConfigFilePath are separate from the goal of this PR. |
94cdf36
to
0660d8a
Compare
Thanks, valid feedback, I improved it, PTAL.
Yes, they are related to the goal. Without this change you can't run the driver in the controller mode on a non-GCE instance.
This is not related to the goal. If it matters that much I can also keep it as it was before. |
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.
mostly looks good, this is something we've been thinking about for a while so thank you for picking it up :)
0660d8a
to
8526aad
Compare
Thanks for your feedback @davidz627, can you now check again? I updated the PR based on your suggestions. Please double-check the docs section. |
/retest |
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.
@rfranzke I think I understand what you're trying to do now - please let me know if I'm mistaken. I've added comments for both "using local or client configuration" (what I think you're trying to do). As well as for "disabling certain driver services" (what this PR description and title led me to believe as the goal)
8526aad
to
2c903e1
Compare
Hi again, meanwhile I had time to update the PR. I was first trying to implement @davidz627's suggestion (#449 (comment)), however, I reached a point where it became clear that this isn't enough for my use-case. Just to reiterate: I want to allow running the controller server of the GCE PD CSI driver separately/outside of the cluster that it is serving - potentially not even on a GCE instance. I reached out to @davidz627 via Slack and we agreed on introducing the earlier discussed TL;DR - The PR now comprises two commits:
The tests are now clearly instantiating only the objects that are really needed for the various servers (e.g., the identity server test does no longer create a fake metadata service). Please take a look, I'm happy to get your feedback on this. |
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.
2 small comments, LGTM besides those two!!
Thanks for the iterations. This looks brilliant :)
2c903e1
to
905c1d4
Compare
/retest |
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.
/lgtm
} | ||
controllerServer = driver.NewControllerServer(gceDriver, cloudProvider) | ||
} else if *cloudConfigFilePath != "" { | ||
klog.Warningf("controller service is disabled but cloud config given - it has no effect") |
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.
nice
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: davidz627, rfranzke 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 |
What type of PR is this?
/kind feature
What this PR does / why we need it:
This PR adds the new
zone
field to the GCE cloud config and makes the controller server independent of the GCE metadata service if bothproject-id
andzone
are present in the config.Also, it adds two new command line flags
run-controller-service
andrun-node-service
(both default totrue
) which allow to particularly disable individual services if not required.This enables the use-case of running the CSI controllers (csi-provisioner, csi-attacher, etc., + the driver controller) separately outside of the cluster, and not necessarily on an GCE compute instance.
Does this PR introduce a user-facing change?: