docker 常用命令

1.开启虚拟机

 Enable-WindowsOptionalFeature -Online -FeatureName $("Microsoft-Hyper-V", "Containers") -All

2.创建Images

docker build -t webapp8 -f ./WebApplication8/Dockerfile .

3.运行Containers

docker run -d -p 9100:80 --name web8 webapp8

4.windows安装Linux子系统

 dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart

5.阿里云私人镜像资源,去阿里云私人复制就行

{
  "registry-mirrors": ["https://******.*******.aliyuncs.com"]
}

posted @ 2024-06-04 15:16  0Behavior  阅读(6)  评论(0编辑  收藏  举报