Is Docker running within WSL or connecting back to Windows?

前端 未结 3 1462
佛祖请我去吃肉
佛祖请我去吃肉 2021-01-04 22:27

After successfully installing Docker in WSL, if I run standard Docker commands, I get connection errors. Runing with sudo or not yields the same result in all examples.

3条回答
  •  感情败类
    2021-01-04 23:07

    The Docker daemon can't run under WSL as it doesn't implement the necessary kernel ABI's. If you're running Docker for Windows, you are probably connecting to the Hyper-V virtual machine that it manages.

    Because it's on a different machine, you will not be able to mount WSL directories as Docker volumes, but you can build images from a WSL directory. This is because on a build, the client creates a tarball and sends it to the daemon.

提交回复
热议问题