首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何在windows下通过"docker-machine create“命令创建虚拟机

如何在windows下通过"docker-machine create“命令创建虚拟机
EN

Stack Overflow用户
提问于 2019-04-26 00:44:09
回答 1查看 1.2K关注 0票数 0

我在Visual Studio 2019中有一个项目。我想学习Docker,并尝试将我的两个web应用程序部署在一起。

当我使用命令" Docker -machine create -d hyperv --hyperv- virtual -switch "stationext“myvm1”Docker创建虚拟机时。我可以在Hyper-V管理器中看到它。但是这个虚拟机使用的是Linux。

如何在板载Windows下通过"docker-machine create“命令创建虚拟机?

创建日志

代码语言:javascript
复制
PS C:\WINDOWS\system32> docker-machine create -d hyperv --hyperv-virtual-switch "stationext" myvm3
Running pre-create checks...
Creating machine...
(myvm3) Copying C:\Users\Sergii\.docker\machine\cache\boot2docker.iso to C:\Users\Sergii\.docker\machine\machines\myvm3\boot2docker.iso...
(myvm3) Creating SSH key...
(myvm3) Creating VM...
(myvm3) Using switch "stationext"
(myvm3) Creating VHD
(myvm3) Starting VM...
(myvm3) Waiting for host to start...
Waiting for machine to be running, this may take a few minutes...
Detecting operating system of created instance...
Waiting for SSH to be available...
Detecting the provisioner...
Provisioning with boot2docker...
Copying certs to the local machine directory...
Copying certs to the remote machine...
Setting Docker configuration on the remote daemon...
Checking connection to Docker...
Docker is up and running!
To see how to connect your Docker Client to the Docker Engine running on this virtual machine, run: C:\Program Files\Docker\Docker\Resources\bin\docker-machine.exe env myvm3

What i see in VM

EN

回答 1

Stack Overflow用户

发布于 2019-04-26 03:22:22

我认为行为是意料之中的,不知道你在哪里看到你将启动windows OS容器,正如你在他们的git上看到的那样,boot2docker是Linux:

https://github.com/boot2docker/boot2docker#readme

同时,您可以看到,为了支持Docker for Windows,这项功能已被弃用。为了在docker上运行windows主机,我认为你应该看看这个:

https://www.docker.com/products/windows-containers

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/55854083

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档