习惯了centos上部署docker容器项目,现在有台win10电脑空闲,于是装上了win10版的docker

去docker官网下载win10版docker CE

默认安装,中间会出现一个选择,大致意思是选择启动win容器还是linux容器,此次下载目的当然是win。

安装完成后右下角会有鲸鱼在喷水的图标,保持等待到图标静态。

装完后电脑会重启。

重启后进入正题:


打开cmd或者powershell(推荐powershell)

使用下docker version 命令查看版本信息


然后去docker官网pullwindows 镜像吧,” https://hub.docker.com/r/microsoft/“windows的镜像不多,不过在慢慢增加,


docker pull microsoft/nanoserver


启动容器(后台)

docker run -d --name winContainer microsoft/nanoserver


进入容器(重点,笑尿,启动了不知道咋进入,找这个找了半小时)


docker exec -it winContainer cmd


之后再补充,还有好多脚本要写T^T



附:

这里推荐一个网址,是当下使用比较多的镜像的一些dockerfile资料

https://github.com/MicrosoftDocs/Virtualization-Documentation/tree/live/windows-container-samples

ASP-NET-Blog-Application Fixing ERROR: client version 1.2x is too old. Minimum supported API v… a year ago
Django Merging Nano Server and Windows Server Core samples 2 years ago
MineCraft Merging Nano Server and Windows Server Core samples 2 years ago
PowerShellDSC_iis-10.0 Merging Nano Server and Windows Server Core samples 2 years ago
apache-http-php fixed code identifier (#653) 5 months ago
apache-http Merging Nano Server and Windows Server Core samples 2 years ago
这里只列出其中几个。





Logo

更多推荐