wsl2安装ubuntu,安装docker,但是docker-compose cloud not be found。(各种坑)

441次阅读
没有评论

运行docker-compose的时候,出现了

The command ‘docker-compose’ could not be found in this WSL 2 distro.
We recommend to activate the WSL integration in Docker Desktop settings.

For details about using Docker Desktop with WSL 2, visit:

https://docs.docker.com/go/wsl2/

这个提示,我找了半天原因,最后才发现这个是个坑。因为你用wsl2的ubuntu的docker,你需要windows的docker desktop同时运行,并且setting->General下面的Use the WSL 2 based engine这个选项要勾选上。然后重启,开着win的docker就可以了。

wsl2安装ubuntu,安装docker,但是docker-compose

李路昌
版权声明:本站原创文章,由 李路昌 2022-10-31发表,共计372字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
评论(没有评论)