简体   繁体   English

如何在 Windows 11 中的 linux 20.04 中运行 Docker

[英]How can run Docker in linux 20.04 in Windows 11

在此处输入图像描述

Hi, I have this problem, trying to running Docker in Ubuntu 20.04 in windows 11 using the WSL, I installed it using the official documentation in https://docs.docker.com/engine/install/linux-postinstall/ , I tried with some commands like: Hi, I have this problem, trying to running Docker in Ubuntu 20.04 in windows 11 using the WSL, I installed it using the official documentation in https://docs.docker.com/engine/install/linux-postinstall/ , I tried使用一些命令,例如:

  • sudo service docker start |须藤服务 docker 开始 | restart重新开始

Show me OK but this didn't work when I tried to execute again the run hello-world command.告诉我确定,但是当我尝试再次执行 run hello-world 命令时这不起作用。

Can you help me please?你能帮我吗?

You should install Docker for Windows and manage it from there, rather than a service within WSL.您应该为 Windows安装 Docker 并从那里管理它,而不是 WSL 中的服务。 Then in the preferences, you can link it to WSL2 , where it'll install the Docker CLI.然后在首选项中,您可以将其链接到 WSL2 ,它将安装 Docker CLI。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM