在 Windows 10 上找不到 docker-machine 命令 [英] docker-machine command not found on windows 10

查看:203
本文介绍了在 Windows 10 上找不到 docker-machine 命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近通过以下网址在 Windows 10 中使用 git bash 安装了 docker 机器:https://github.com/docker/machine/releases/tag/v0.16.2

I have recently installed docker machine using using git bash in windows 10 from following this url: https://github.com/docker/machine/releases/tag/v0.16.2

当我在 git bash 上运行docker-machine version"命令时,它工作正常并提供当前版本的 docker 机器,但是当我在命令提示符下运行相同的命令时,它无法识别该命令

And when I'm running "docker-machine version" command on git bash, it is working fine and giving current version of docker machine, but when I'm running same command on command prompt, it is not recognizing the command

推荐答案

Git bash 使用与 Windows 隔离的 Linux 环境,因此您无法从 Windows 运行 Linux 程序.您只需要在 Git bash 中使用 Docker.

Git bash uses a Linux environment isolated from Windows, so you can't run Linux programs from Windows. You need to use Docker solely within Git bash.

为此(在 Windows 下使用 Linux 进行开发),我建议您使用 WSL 而不是 Git bash,后者仅供 Git 使用.

For this purpose (using Linux for development under Windows), I recommend you to use WSL instead of Git bash which is meant for Git use only.

如果您更熟悉 Windows,则可以使用 MinikubeDockerWindows 桌面

If you are more familiar with Windows, you can develop and run Docker apps locally on Windows without Linux, by using either Minikube, or Docker Desktop for Windows

这篇关于在 Windows 10 上找不到 docker-machine 命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆