-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Add start
and stop
command to kind
.
#2715
Comments
Are you sure this is working properly? What host environment? IIRC in the past we did not do this because it didn't actually work correctly. That may not be true today due to various fixes ... |
IIRC it works for single node, but it will fail for multi-node if the runtime assign different IPs to the node |
seems like this is on the backlog until #1689 is fixed |
In case it's interesting we solved this in our fork of KinD for single node clusters by letting Docker assign a stable IP address and then using it to prevent issues with IP address changes. (getoutreach#4 and getoutreach#5) It's not perfect but it works. One of these days I want to pitch the few changes we made in PRs here, but just haven't gotten to It so hopefully some of that code is useful for anyone wanting to implement a start/stop until it's done here. |
Thanks for sharing!
If you do, please see our contributing guide https://kind.sigs.k8s.io/docs/contributing/getting-started/ Also FWIW there's promising alternatives in #2671 (though, that reallly should have been discussed more up front as well, and probably same thing for the changes being PRed to kubeadm). |
Since multi-node cluster (with a single control plane node) is working after restarting docker. I think it is enough to just call docker stop/start to implement this? |
Note if you start and stop a kind node in Docker, the IP will change for the container, which breaks the cluster. At least that was the case when I last worked in an environment using KinD in 2023, so that's what required the changes I originally Sorry I never got around to starting a discussion around those changes before I stopped working there 😿 |
That shouldn't have been breaking kind even in 2023. It was mitigated in may 2022. #2775 There are other issues though, with podman (and maybe nerdctl) and with multiple-control-plane nodes / "HA" (see above). |
What would you like to be added:
Add a
start
andstop
command tokind
.This would be a light abstraction on
docker kill
ordocker stop
anddocker start
. It would also do some validation that start/stop is supported for the cluster (e.g. is it multi-node? etc).note, I've not considered podman support, but imagine this could be possible
Why is this needed:
For the sake of local resources, I sometimes use
docker kill
to turn down running (single-node) kind clusters anddocker start
to bring them back up. It could be nice to do this entirely throughkind
.Curious if the
kind
project would be interested in a contribution around this functionality! No worries if not, thanks for your consideration 😄!The text was updated successfully, but these errors were encountered: