<p>I want to ssh minikube/docker-desktop, but I cant. How can i do that?</p>
<pre><code>NAME       STATUS   ROLES                  AGE     VERSION   INTERNAL-IP    EXTERNAL-IP   OS-IMAGE             KERNEL-VERSION      CONTAINER-RUNTIME
minikube   Ready    control-plane,master   4m47s   v1.20.2   192.168.49.2   &lt;none&gt;        Ubuntu 20.04.2 LTS   4.19.121-linuxkit   docker://20.10.6

ssh minikube
ssh: Could not resolve hostname minikube: nodename nor servname provided, or not known
</code></pre>
<p>I am learning K8s and able to ssh while working on K8s hands-on labs available online. I'd like t test some stuff on my local environment.</p>

cosmos-1905-14
<p><code>minikube</code> is the node name within the Kubernetes API, not a hostname in this case. Minikube offers a wrapper <a href="https://minikube.sigs.k8s.io/docs/commands/ssh/" rel="nofollow noreferrer"><code>minikube ssh</code></a> command to automate pulling the IP and whatnot. Docker Desktop does not offer an official way to get a shell in the VM as it's a single-purpose appliance and they want it in a known state, but you can fake it by running a super-superuser container like <code>docker run -it --rm --privileged --pid=host justincormack/nsenter1</code> to break out into the host namespaces.</p>
