<p>I can't connect Docker CLI to the remote Docker demon inside minikube.</p>
<p>I've done <code>minikube delete</code> and then <code>minikube start --driver=hyperv</code>   but when I do &amp; <code>minikube -p minikube docker-env | Invoke-Expression</code> it comes back with a weird error which is:</p>
<pre><code>You: The term 'You' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Invoke-Expression: Cannot bind argument to parameter 'Command' because it is an empty string.
Invoke-Expression:
Line |
   1 |  &amp; minikube -p minikube docker-env | Invoke-Expression
     |                                      ~~~~~~~~~~~~~~~~~
     | The string is missing the terminator: '.
</code></pre>
<p>Can anybody help with this?</p>

<p>This is a community wiki answer posted for better visibility. Feel free to expand it.</p>
<p>As already discussed in the comments the solution is to use the <a href="https://minikube.sigs.k8s.io/docs/commands/docker-env/" rel="nofollow noreferrer">minikube docker-env command</a>:</p>
<blockquote>
<pre><code>minikube docker-env
</code></pre>
<p>Configure environment to use minikube’s Docker daemon</p>
<p><strong>Synopsis</strong></p>
<p>Sets up docker env variables; similar to <code>$(docker-machine env)</code>.</p>
<pre><code>minikube docker-env [flags]
</code></pre>
</blockquote>
<p>Notice the <code>--shell</code> option:</p>
<pre><code>  --shell string   Force environment to be configured for a specified shell: [fish, cmd, powershell, tcsh, bash, zsh], default is auto-detect
</code></pre>
