Merge pull request #24033 from Yuaninga/patch-2

[zh] add the missing content in [zh/docs/setup/production-environment/container-runtimes.md]
This commit is contained in:
Kubernetes Prow Robot 2020-09-24 22:41:11 -07:00 committed by GitHub
commit 05d9317d65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 30 additions and 0 deletions

View File

@ -842,6 +842,36 @@ systemctl restart containerd
# 重启 containerd
systemctl restart containerd
```
{{% /tab %}}
{{% tab name="Windows/(PowerShell)" %}}
```powershell
# (安装 containerd
# 下载 contianerd
cmd /c curl -OL https://github.com/containerd/containerd/releases/download/v1.4.0-beta.2/containerd-1.4.0-beta.2-windows-amd64.tar.gz
cmd /c tar xvf .\containerd-1.4.0-beta.2-windows-amd64.tar.gz
```
```powershell
# 添加开机启动
Copy-Item -Path ".\bin\" -Destination "C:\Program Files\containerd" -Recurse -Force
cd C:\Program Files\containerd\
.\containerd.exe config default | Out-File config.toml -Encoding ascii
# 检查配置文件主要看以下三个参数
# sandbox_image 的镜像地址
# CNI 的 bin_dir 和 conf_dir 路径
Get-Content config.toml
```
```powershell
# containerd 注册服务
.\containerd.exe --register-service
# 启动 containerd
Start-Service containerd
```
{{% /tab %}}
{{< /tabs >}}