超详细Windows11家庭中文版系统安装Docker-20230401
https://blog.csdn.net/m0_37802038/article/details/129893827
Hyper-V.cmd
pushd "F:\2024"
dir /b %SystemRoot%\servicing\Packages\*Hyper-V*.mum >hyper-v.txt
for /f %%i in ('findstr /i . hyper-v.txt 2^>nul') do dism /online /norestart /add-package:"%SystemRoot%\servicing\Packages\%%i"
del hyper-v.txt
Dism /online /enable-feature /featurename:Microsoft-Hyper-V-All /LimitAccess /ALL
docker run hello-world 报错 Docker Engine 下加下面的内容
"registry-mirrors": [
"https://registry.docker-cn.com",
"https://dockerproxy.com",
"https://hub-mirror.c.163.com",
"https://mirror.baidubce.com",
"https://ccr.ccs.tencentyun.com"
]
进入项目根目录
右键项目-添加-Docker支持,目标OS选择Linux。
docker build -t webapplication1 -f ./WebApplication1/Dockerfile .
cd F:\2024
etcoreDocker
docker build -t webapplication1 -f ./WebApplication1/Dockerfile .
启动容器:docker run -d -p 5000:80 --name web1 webapplication1
使用docker ps查看运行中的容器: