-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Minikube start with ssh
as driver ignores --ssh-key
parameter
#10289
Comments
Thanks for reporting, it seems like this also happens on Windows - but haven't really seen it on Linux... Since this is the second start ("updating the running"), the logs might not have all the details though. |
Note that EDIT: Does it work better with "$HOME/.ssh/id_rsa" ? It seems that it is not expanding the tilde.
|
These messages are "normal":
* assuming the VM is set up... And it should give errors, if there was something wrong with the key:
There is an old (2016) TODO, to validate the key in PreCreateCheck... |
I can confirm that it does seem to be a little stupid, when not using the external
There is supposed to be a publickey (from file or from agent) in there, otherwise it will be hard to get in... Unfortunately the NativeClient is 1) stupid and 2) hardcoded, so it doesn't add the default auth methods. |
@afbjorklund thanks for following up with this issue. I've tried expanding the path into a full one manually which didn't help either. I am currently using docker driver to bypass this issue, but if what I'm experiencing is universal, it seems the |
It's the default, but usually we add some more too :-) Broken on all platforms, but you should be able to use --ssh-key "$HOME/.ssh/id_rsa" https://github.com/kubernetes/minikube/blob/v1.17.0/pkg/minikube/sshutil/sshutil.go#L43_L46 When fixed, it will support Basically the same as when using |
The current workaround is: (possible to change user and port too)
Because using tilde and native ssh client doesn't work at the moment. |
Unfortunately, using |
What is the version of Can you try to run the command with It looks like it is using the wrong user, but maybe something else is off. --ssh-ip-address=192.168.233.5 --ssh-key=$HOME/.ssh/id_rsa --ssh-user=fizzytidus root@192.168.233.5 -p 22 (and no sign of the -i parameter either, so not "working")
It did call the external
It should be possible:
It probably used the previous profile/config ?
|
Sorry I wasn't clear about what I meant by
I meant to say it thinks my SSH client is Also this line ls it how minikube calls the ssh client? I tried to run
as shown in the log on my system, and it doesn't return anything to either If I add the missing So I suspect if I change the code handling SSH to honour the user and key supplied, the issue should be resolved. Can I attempt to do that? I can try to submit a PR to fix it. |
Usually
You can either delete the old "ssh" driver profile (it's just the connection parameters anyway), or start a new one (-p) |
Steps to reproduce the issue:
minikube start --driver=ssh --ssh-ip-address=192.168.233.5 --ssh-key='~/.ssh/id_rsa' --ssh-user=songford --alsologtostderr -v=4
Full output of failed command:
With
--alsologtostderr -v=4
:But I am able to use
ssh -i ~/.ssh/id_rsa songford@192.168.233.5
to connect to this VM.The text was updated successfully, but these errors were encountered: