-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Deprecate HyperKit driver with warning #21024
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
Conversation
|
Welcome @divysinghvi! |
|
Hi @divysinghvi. Thanks for your PR. I'm waiting for a kubernetes 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-sigs/prow repository. |
|
Can one of the admins verify this patch? |
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.
The warning looks good, but we also need to mark the driver.Priority to Deprecated in pkg/minikube/registry/drvs/hyperkit/hyperkit.go.
cmd/minikube/cmd/start.go
Outdated
| return | ||
| } | ||
| out.WarningT(`The 'hyperkit' driver is deprecated and will be removed in a future release. | ||
| Please consider using an alternative driver such as 'docker', 'qemu', or 'vfkit'.`) |
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.
The preferred driver for macOS is vfkit, and then qemu. docker requires docker desktop which is not open source, so we should not recommend it.
So let's use "such as vfkit, qemu, or docker"
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.
Kubernetes project does not have a problem with recommending using Docker in various places, though.
|
@divysinghvi I think this change can fix #21012. We don't need to do any other change now. The driver build works, and we want to remove it later, but for now marking it as depracated and recommending other drivers is all we need to do. We also need to update hyperkit docs: It should have as similar warning that the driver will be removed in future version and recommend other drivers, linking to the other drivers docs. |
|
@nirs Thanks a lot for your help! 🙌 Regarding the HyperKit documentation — I’d be happy to work on it and add a similar warning to that too |
|
@nirs While working on this, I noticed that the VirtualBox driver documentation page also does not mention that the driver is deprecated: https://minikube.sigs.k8s.io/docs/drivers/virtualbox/. It might be helpful to update that page as well. |
cmd/minikube/cmd/start.go
Outdated
| suggestedDriver := driver.HyperKit | ||
| suggestedDriver := driver.VFKit | ||
| if runtime.GOARCH == "arm64" { | ||
| suggestedDriver = driver.QEMU |
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.
This is wrong, vfkit is the preferred driver on both arm64 and amd64.
cmd/minikube/cmd/start.go
Outdated
| } | ||
| out.WarningT(`The 'hyperkit' driver is deprecated and will be removed in a future release. | ||
| Please consider using an alternative driver such as 'docker', 'qemu', or 'vfkit'.`) | ||
| Please consider using an alternative driver such as vfkit, qemu, or docker`) |
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.
I would keep the quoting, unless most other warnings do not quote driver names.
cmd/minikube/cmd/start.go
Outdated
| suggestedDriver := driver.VFKit | ||
| if runtime.GOARCH == "arm64" { | ||
| suggestedDriver = driver.QEMU | ||
| } |
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.
We need to update the warning bellow - it says:
You can use alternative drivers such as docker or {{.driver}}.
https://minikube.sigs.k8s.io/docs/drivers/docker/
https://minikube.sigs.k8s.io/docs/drivers/{{.driver}}/
It should say:
You can use alternative drivers such as vfkit, qemu, or docker.
https://minikube.sigs.k8s.io/docs/drivers/vfkit/
https://minikube.sigs.k8s.io/docs/drivers/qemu/
https://minikube.sigs.k8s.io/docs/drivers/docker/
cmd/minikube/cmd/start.go
Outdated
| return | ||
| } | ||
| suggestedDriver := driver.HyperKit | ||
| suggestedDriver := driver.VFKit |
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.
We can also remove this variable and the {{.driver}} template, since we don't need to select a driver based on arch, and we have several recommendations.
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.
okay so i will change it to list it like you suggested
You can use alternative drivers such as vfkit, qemu, or docker. https://minikube.sigs.k8s.io/docs/drivers/vfkit/ https://minikube.sigs.k8s.io/docs/drivers/qemu/ https://minikube.sigs.k8s.io/docs/drivers/docker/
i will also add this to HyperKit warning too
@divysinghvi did you miss this comment? |
|
@nirs You're right — I missed that, apologies! I'll update driver.Priority to Deprecated in pkg/minikube/registry/drvs/hyperkit/hyperkit.go and push the change shortly. Thanks for pointing it out! |
|
/lgtm |
|
@nirs: changing LGTM is restricted to collaborators In response to this:
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. |
|
/ok-to-test |
|
kvm2 driver with docker runtime Times for minikube start: 52.3s 51.5s 51.5s 51.1s 47.9s Times for minikube ingress: 15.0s 15.0s 14.5s 15.5s 15.0s docker driver with docker runtime Times for minikube start: 23.6s 23.4s 23.5s 23.0s 25.5s Times for minikube ingress: 13.8s 13.3s 13.3s 12.3s 11.3s docker driver with containerd runtime Times for minikube ingress: 23.8s 39.8s 22.8s 22.8s 27.8s Times for minikube (PR 21024) start: 24.2s 21.7s 22.4s 25.5s 21.4s |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: afbjorklund, divysinghvi, medyagh, nirs 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 |
|
@divysinghvi thank you for this contribution, look forward to see more :) |
* deprecate hyperkit driver with user-facing warning * apply review suggestions from PR kubernetes#21024 * apply review suggestions from PR kubernetes#21024 * apply review suggestions from PR kubernetes#21024-updating registery priority
* deprecate hyperkit driver with user-facing warning * apply review suggestions from PR kubernetes#21024 * apply review suggestions from PR kubernetes#21024 * apply review suggestions from PR kubernetes#21024-updating registery priority
This PR deprecates the HyperKit driver by displaying a user-facing warning when it is selected via
--driver=hyperkit.docker,qemu, orvfkit.Partially addresses #21012