1.在docker hub上下載docker.dmg文件并進(jìn)行安裝
2.查看當(dāng)前docker 版本信息及k8s版本號(hào)
3.下載阿里云鏡像腳本文件
git clone https://github.com/AliyunContainerService/k8s-for-docker-desktop.git
4.切換k8s對(duì)應(yīng)版本號(hào)分支
5.配置docker Engine(使用中科大鏡像加速地址https://docker.mirrors.ustc.edu.cn)
{
"experimental": true,
"insecure-registries": [
"hub.zhubaoe.cn:5555",
"134.175.60.198:5555"
],
"debug": true,
"registry-mirrors": [
"https://docker.mirrors.ustc.edu.cn"
]
}
6.修改docker 配置信息建議(2核,4g)
7.執(zhí)行./load_images.sh 腳本命令(拉取阿里鏡像及替換對(duì)應(yīng)名稱)
8.開啟在docker設(shè)置中開啟k8s
9.查看運(yùn)行日志(特別重要**)
pred='process matches ".*(ocker|vpnkit).*"
|| (process in {"taskgated-helper", "launchservicesd", "kernel"} && eventMessage contains[c] "docker")'
/usr/bin/log stream --style syslog --level=debug --color=always --predicate "$pred"
參考文獻(xiàn)
https://github.com/AliyunContainerService/k8s-for-docker-desktop