gpt4 book ai didi

macos - 如何在 OS X 中运行 "docker-machine create"?

转载 作者:IT老高 更新时间:2023-10-28 12:43:42 25 4
gpt4 key购买 nike

我启动了 Docker,现在正在学习教程,但据我所知,我无法在 OS X 上运行 docker-machine 命令。

The documentation states运行以下命令来创建本地虚拟机:

docker-machine create --driver virtualbox manager

但是,此命令在 OS X (11.6) 中不起作用,并出现以下错误:

Running pre-create checks...
Error with pre-create check: "VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path"

我尝试安装虚拟机;但是,another page clearly states你不能将它安装在你的本地机器上:

VirtualBox prior to version 4.3.30 must NOT be installed (it is incompatible with Docker for Mac)

Note: If your system does not satisfy these requirements, you can install Docker Toolbox, which uses Oracle VirtualBox instead of HyperKit.

所以我只安装了 Docker for Mac 而没有安装 virtualbox。那么我在这里错过了什么? The example page说你可以在 OS X 上运行教程,所以我想知道我该如何继续......

You can follow along and run this example using Docker for Mac, Docker for Windows or Docker for Linux.

最佳答案

我今天遇到了同样的问题,并通过安装 VirtualBox 作为安装 Docker for Mac 后的附加步骤来解决它(我使用 brew install --cask virtualbox 这样做)

我不记得以前必须进行额外的安装,但也许我已经安装了 VirtualBox,因为另一个工具(如 Vagrant)。无论如何,这在 Docker Machine 中有解释。文档:

If you are using Docker for Mac

Docker for Mac uses HyperKit, a lightweight macOS virtualizationsolution built on top of the Hypervisor.framework in macOS 10.10Yosemite and higher.

Currently, there is no docker-machine create driver for HyperKit, soyou will use virtualbox driver to create local machines. (See theDocker Machine driver for Oracle VirtualBox.) Note that you can runboth HyperKit and Oracle VirtualBox on the same system. To learn more,see Docker for Mac vs. Docker Toolbox.

  • Make sure you have the latest VirtualBox correctly installed on your system (either as part of an earlier Toolbox install, or manualinstall).

关于macos - 如何在 OS X 中运行 "docker-machine create"?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42079458/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com