文章目录
url:Docker入门学习
由于是学习记录.一边操作.一边记录.杂乱无章.
来自于PowerShell代码运行
第一次失败.
PS E:\GitProjects\Docker\doodle\cheers2019> docker build -t gwdsss/cheers2019
"docker build" requires exactly 1 argument.
See 'docker build --help'.
Usage: docker build [OPTIONS] PATH | URL | -
Build an image from a Dockerfile
第二次失败.
以为少个.点
PS E:\GitProjects\Docker\doodle\cheers2019> docker build -t gwdsss/cheers2019 .
error during connect: Post http://%2F%2F.%2Fpipe%2Fdocker_engine/v1.40/build?buildargs=%7B%7D&cachefrom=%5B%5D&cgroupparent=&cpuperiod=0&cpuquota=0&cpusetcpus=&cpusetmems=&cpushares=0&dockerfile=Dockerfile&labels=%7B%7D&memory=0&memswap=0&networkmode=default&rm=1&session=s962i79etq4bulj15tusjz77u&shmsize=0&t=gwdsss%2Fcheers2019&target=&ulimits=null&version=1: open //./pipe/docker_engine: The system cannot find the file specified. In the default daemon configuration on Windows, the docker client must be run elevated to connect. This error may also indicate that the docker daemon is not running.
可能是服务未开?
(2020-1-7 15:11:04)
休息
启动.
how?
过了一会儿.提示.
查找
D:\cygwin64\bin
打开
Docker Machine is not installed. Please re-run the Toolbox Installer and try again.
Looks like something went wrong in step ´Looking for vboxmanage.exe´... Press any key to continue...
出现错误.
url:简书学习:未果.
寻找Hyper-V
重新启动Docker
bash: D:\Program Files\Oracle\VirtualBox\VBoxManage.exe: 未找到命令
bash: D:\Program Files\Docker Toolbox\docker-machine.exe: 未找到命令
Looks like something went wrong in step ´Checking if machine default exists´... Press any key to continue...
可是存在.
这个就可以了.
url:CSDN解决文章
打开
环境变量是DOCKER_TOOLBOX_INStALL_PATH,后者对应的环境变量是VBOX_MSI_INSTALL_PATH或者VBOX_INSTALL_PATH
存在证明.
还是存在.
重启电脑.
(2020-1-7 16:52:17)
(2020-1-7 16:55:33)
失败.
是不是bash有问题?
去官网寻找帮助.
url:官网文档
图片
根据文档图片.知道用的是minGW.那么切换切换bash.
(2020-1-7 17:25:32)
安装minGW
之前用过.做C++和C的.
安装bash.
猜想是这个.
报错:
第一张未保存忽略报错即可.
类似的问题太多.
没有外网?
无网络造成的.
任务管理器显示无流量经过.
这个问题解决地很差劲.很浪费时间.
警惕循环问题.
从根本上解决.
由于过于复杂.重新安装Docker
安装git-?
悔不当初.重新来过.
简洁没有成功.反而浪费了时间.
(2020-1-7 18:10:03)
百度得知git bash下
视频
bilibili
未果
直接解决快捷方式的问题.[正解]
也就是百度bash.exe
“C:\Program Files\Git\bin\bash.exe” --login -i “D:\Program Files\Docker Toolbox\start.sh”
可以自己修改.
怪不得.这个确实没有.
替换即可.
好的.问题解决了.就是这么简单.
(2020-1-7 18:45:28)
我走的路就是这么复杂.坑了.自己.
复杂.
一开始就不应该自以为bash.exe自己可以找到.
重新安装也许对的?但是已经产生了?快捷方式?
Creating CA: C:\Users\71027\.docker\machine\certs\ca.pem
Creating client certificate: C:\Users\71027\.docker\machine\certs\cert.pem
Running pre-create checks...
(default) Image cache directory does not exist, creating it at C:\Users\71027\.docker\machine\cache...
(default) No default Boot2Docker ISO found locally, downloading the latest release...
(default) Latest release for github.com/boot2docker/boot2docker is v19.03.5
(default) Downloading C:\Users\71027\.docker\machine\cache\boot2docker.iso from https://github.com/boot2docker/boot2docker/releases/download/v19.03.5/boot2docker.iso...
有反应了.安装中?
等待.
解决
新的问题
这一次,轻易地发现问题.
附加信息.
(default) Downloading C:\Users\--\.docker\machine\cache\boot2docker.iso from https://github.com/boot2docker/boot2docker/releases/download/v19.03.5/boot2docker.iso...
(default) 0%Error removing file: Error removing temporary download file: remove C:\Users\--\.docker\machine\cache\boot2docker.iso.tmp752792803: The process cannot access the file because it is being used by another process.
(default)
Error with pre-create check: "read tcp 192.168.1.4:64848->52.216.100.139:443: wsarecv: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond."
Looks like something went wrong in step ´Checking if machine default exists´... Press any key to continue...
ping一下
网络不稳定.
直接移动这个文件.
(2020-1-7 19:02:36)
半小时后收工.19:41-20:11
定好明天的计划.
休息.(2020-1-7 19:12:46)
成功
(2020-1-8 7:44:18)
昨晚尝试成功.
Running pre-create checks...
Creating machine...
(default) Copying C:\Users\71027\.docker\machine\cache\boot2docker.iso to C:\Users\71027\.docker\machine\machines\default\boot2docker.iso...
(default) Creating VirtualBox VM...
(default) Creating SSH key...
(default) Starting the VM...
(default) Check network to re-create if needed...
(default) Windows might ask for the permission to create a network adapter. Sometimes, such confirmation window is minimized in the taskbar.
(default) Found a new host-only adapter: "VirtualBox Host-Only Ethernet Adapter #2"
(default) Windows might ask for the permission to configure a network adapter. Sometimes, such confirmation window is minimized in the taskbar.
(default) Windows might ask for the permission to configure a dhcp server. Sometimes, such confirmation window is minimized in the taskbar.
(default) Waiting for an IP...
等待.
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: D:\Program Files\Docker Toolbox\docker-machine.exe env default
## .
## ## ## ==
## ## ## ## ## ===
/"""""""""""""""""\___/ ===
~~~ {~~ ~~~~ ~~~ ~~~~ ~~~ ~ / ===- ~~~
\______ o __/
\ \ __/
\____\_______/
docker is configured to use the default machine with IP 192.168.99.100
For help getting started, check out the docs at https://docs.docker.com
Start interactive shell
下一步与新的问题
$ docker run hello-world
Unable to find image 'hello-world:latest' locally
D:\Program Files\Docker Toolbox\docker.exe: Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: TLS handshake timeout.
See 'D:\Program Files\Docker Toolbox\docker.exe run --help'
(2020-1-8 0:02:24)昨日备忘.
搜索时学的正则.
不幸的是.正则也走了弯路.
浪费时间一方面.浪费了精力.身体被掏空了一半.休息了.(2020-1-7 18:53:04)
关于.的用法.