Skip to content

Commit

Permalink
[zh-cn] sync contribute/* container-runtimes
Browse files Browse the repository at this point in the history
Signed-off-by: xin.li <xin.li@daocloud.io>
  • Loading branch information
my-git9 committed Aug 27, 2023
1 parent b32835f commit 6d29856
Show file tree
Hide file tree
Showing 6 changed files with 85 additions and 24 deletions.
26 changes: 25 additions & 1 deletion content/zh-cn/docs/contribute/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,10 @@ class first,second,third white
<!--
Figure 1. Getting started for a new contributor.
Figure 1 outlines a roadmap for new contributors. You can follow some or all of the steps for `Sign up` and `Review`. Now you are ready to open PRs that achieve your contribution objectives with some listed under `Open PR`. Again, questions are always welcome!
Figure 1 outlines a roadmap for new contributors. You can follow some or
all of the steps for `Sign up` and `Review`. Now you are ready to open PRs
that achieve your contribution objectives with some listed under `Open PR`.
Again, questions are always welcome!
-->
图 1. 新手入门指示。

Expand Down Expand Up @@ -240,6 +243,27 @@ Figure 2. Preparation for your first contribution.
- 了解[页面内容类型](/zh-cn/docs/contribute/style/page-content-types/)
[Hugo 短代码](/zh-cn/docs/contribute/style/hugo-shortcodes/)

<!--
## Getting help when contributing
Making your first contribution can be overwhelming. The
[New Contributor Ambassadors](https://github.com/kubernetes/website#new-contributor-ambassadors)
are there to walk you through making your first few contributions.
You can reach out to them in the [Kubernetes Slack](https://slack.k8s.io/)
preferably in the `#sig-docs` channel. There is also the
[New Contributors Meet and Greet call](https://www.kubernetes.dev/resources/calendar/)
that happens on the first Tuesday of every month. You can interact with
the New Contributor Ambassadors and get your queries resolved here.
-->
## 贡献时获取帮助

做出第一个贡献可能会让人感觉比较困难。
[新贡献者大使](https://github.com/kubernetes/website#new-contributor-ambassadors)
将引导你完成最初的一些贡献。你可以在 [Kubernetes Slack](https://slack.k8s.io/)
中联系他们,最好是在 `#sig-docs` 频道中。还有每月第一个星期二举行的
[新贡献者见面会](https://www.kubernetes.dev/resources/calendar/)
你可以在此处与新贡献者大使互动并解决你的疑问。

<!--
## Next steps
Expand Down
1 change: 0 additions & 1 deletion content/zh-cn/docs/contribute/style/page-content-types.md
Original file line number Diff line number Diff line change
Expand Up @@ -405,4 +405,3 @@ Examples of published tool reference pages are:
- 了解[样式指南](/zh-cn/docs/contribute/style/style-guide/)
- 了解[内容指南](/zh-cn/docs/contribute/style/content-guide/)
- 了解[内容组织](/zh-cn/docs/contribute/style/content-organization/)

25 changes: 19 additions & 6 deletions content/zh-cn/docs/contribute/style/style-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -553,7 +553,7 @@ To specify the Kubernetes version for a task or tutorial page, include
[任务模板](/zh-cn/docs/contribute/style/page-content-types/#task)
[教程模板](/zh-cn/docs/contribute/style/page-content-types/#tutorial)
`prerequisites` 小节定义 Kubernetes 版本。
页面保存之后,`prerequisites` 小节会显示为 **开始之前**
页面保存之后,`prerequisites` 小节会显示为**开始之前**

如果要为任务或教程页面指定 Kubernetes 版本,可以在文件的前言部分包含
`min-kubernetes-server-version` 信息。
Expand Down Expand Up @@ -700,7 +700,7 @@ The output is:

使用短代码 `{{</* note */>}}` 来突出显示某种提示或者有助于读者的信息。

例如:
例如

```
{{</* note */>}}
Expand All @@ -714,7 +714,7 @@ The output is:
<!--
You can _still_ use Markdown inside these callouts.
-->
在这类短代码中仍然 _可以_ 使用 Markdown 语法。
在这类短代码中仍然**可以**使用 Markdown 语法。
{{< /note >}}

<!--
Expand Down Expand Up @@ -1234,8 +1234,7 @@ This page teaches you how to use pods. | In this page, we are going to learn abo

### 避免使用“我们”

在句子中使用“我们”会让人感到困惑,因为读者可能不知道这里的
“我们”指的是谁。
在句子中使用“我们”会让人感到困惑,因为读者可能不知道这里的“我们”指的是谁。

{{< table caption = "要避免的模式" >}}
可以 | 不可以
Expand Down Expand Up @@ -1283,7 +1282,7 @@ is the [Deprecated API migration guide](/docs/reference/using-api/deprecation-gu
### 避免关于将来的陈述

要避免对将来作出承诺或暗示。如果你需要讨论的是 Alpha 功能特性,
可以将相关文字放在一个单独的标题下,标示为 Alpha 版本信息。
可以将相关文字放在一个单独的标题下,标识为 Alpha 版本信息。

此规则的一个例外是对未来版本中计划移除的已废弃功能选项的文档。
此类文档的例子之一是[已弃用 API 迁移指南](/zh-cn/docs/reference/using-api/deprecation-guide/)
Expand Down Expand Up @@ -1341,6 +1340,20 @@ These steps ... | These simple steps ...
这些步骤... | 这些简单的步骤...
{{< /table >}}

<!--
### EditorConfig file
The Kubernetes project maintains an EditorConfig file that sets common style preferences in text editors
such as VS Code. You can use this file if you want to ensure that your contributions are consistent with
the rest of the project. To view the file, refer to
[`.editorconfig`](https://github.com/kubernetes/website/blob/main/.editorconfig) in the repository root.
-->
### 编辑器配置文件

Kubernetes 项目维护一个 EditorConfig 文件,用于设置文本编辑器(例如 VS Code)中的常见样式首选项。
如果你想确保你的贡献与项目的其余部分样式保持一致,则可以使用此文件。
要查看该文件,请参阅项目仓库根目录的
[`.editorconfig`](https://github.com/kubernetes/website/blob/main/.editorconfig)

## {{% heading "whatsnext" %}}

<!--
Expand Down
14 changes: 2 additions & 12 deletions content/zh-cn/docs/contribute/style/write-new-topic.md
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ the topic. In your topic file, use the `codenew` shortcode:
其中 `<LANG>` 是该主题的语言。在主题文件中使用 `codenew` 短代码:

```none
{{</* codenew file="<RELPATH>/my-example-yaml>" */>}}
{{%/* codenew file="<RELPATH>/my-example-yaml>" */%}}
```

<!--
Expand All @@ -245,19 +245,9 @@ file located at `/content/en/examples/pods/storage/gce-volume.yaml`.
文件。

```none
{{</* codenew file="pods/storage/gce-volume.yaml" */>}}
{{%/* codenew file="pods/storage/gce-volume.yaml" */%}}
```

<!--
To show raw Hugo shortcodes as in the above example and prevent Hugo
from interpreting them, use C-style comments directly after the `<` and before
the `>` characters. View the code for this page for an example.
-->
{{< note >}}
要展示上述示例中的原始 Hugo 短代码并避免 Hugo 对其进行解释,
请直接在 `<` 字符之后和 `>` 字符之前使用 C 样式注释。请查看此页面的代码。
{{< /note >}}

<!--
## Showing how to create an API object from a configuration file
Expand Down
15 changes: 11 additions & 4 deletions content/zh-cn/docs/contribute/suggesting-improvements.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,29 @@ content_type: concept
weight: 10
card:
name: contribute
weight: 20
weight: 15
anchors:
- anchor: "#opening-an-issue"
title: 提出内容改进建议
---
<!--
title: Suggesting content improvements
content_type: concept
weight: 10
card:
name: contribute
weight: 20
weight: 15
anchors:
- anchor: "#opening-an-issue"
title: Suggest content improvements
-->

<!-- overview -->

<!--
If you notice an issue with Kubernetes documentation or have an idea for new content, then open an issue. All you need is a [GitHub account](https://github.com/join) and a web browser.
If you notice an issue with Kubernetes documentation or have an idea for new content,
then open an issue. All you need is a [GitHub account](https://github.com/join) and
a web browser.
In most cases, new work on Kubernetes documentation begins with an issue in GitHub. Kubernetes contributors
then review, categorize and tag issues as needed. Next, you or another member
Expand Down Expand Up @@ -115,4 +123,3 @@ fellow contributors. For example, "The docs are terrible" is not
例如:`Introduced by #987654`
- 遵从[行为准则](/zh-cn/community/code-of-conduct/)。尊重同行贡献者。
例如,"The docs are terrible" 就是无用且无礼的反馈。

Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,18 @@ the `cgroupDriver` field under `KubeletConfiguration`, kubeadm defaults it to `s
`KubeletConfiguration` 下设置 `cgroupDriver` 字段,kubeadm 默认使用 `systemd`。
{{< /note >}}

<!--
In Kubernetes v1.28, with the `KubeletCgroupDriverFromCRI`
[feature gate](/docs/reference/command-line-tools-reference/feature-gates/)
enabled and a container runtime that supports the `RuntimeConfig` CRI RPC,
the kubelet automatically detects the appropriate cgroup driver from the runtime,
and ignores the `cgroupDriver` setting within the kubelet configuration.
-->
在 Kubernetes v1.28 中,启用 `KubeletCgroupDriverFromCRI`
[特性门控](/zh-cn/docs/reference/command-line-tools-reference/feature-gates/)结合支持
`RuntimeConfig` CRI RPC 的容器运行时,kubelet 会自动从运行时检测适当的 Cgroup
驱动程序,并忽略 kubelet 配置中的 `cgroupDriver` 设置。

<!--
If you configure `systemd` as the cgroup driver for the kubelet, you must also
configure `systemd` as the cgroup driver for the container runtime. Refer to
Expand Down Expand Up @@ -437,6 +449,14 @@ When using kubeadm, manually configure the
当使用 kubeadm 时,请手动配置
[kubelet 的 cgroup 驱动](/zh-cn/docs/tasks/administer-cluster/kubeadm/configure-cgroup-driver/#configuring-the-kubelet-cgroup-driver)

<!--
In Kubernetes v1.28, you can enable automatic detection of the
cgroup driver as an alpha feature. See [systemd cgroup driver](#systemd-cgroup-driver)
for more details.
-->
在 Kubernetes v1.28 中,你可以启用 Cgroup 驱动程序的自动检测的 Alpha 级别特性。
详情参阅 [systemd cgroup 驱动](#systemd-cgroup-driver)

<!--
#### Overriding the sandbox (pause) image {#override-pause-image-containerd}
Expand Down Expand Up @@ -509,6 +529,14 @@ in sync.
你还应该注意当使用 CRI-O 时,并且 CRI-O 的 cgroup 设置为 `cgroupfs` 时,必须将 `conmon_cgroup` 设置为值 `pod`
通常需要保持 kubelet 的 cgroup 驱动配置(通常通过 kubeadm 完成)和 CRI-O 同步。

<!--
In Kubernetes v1.28, you can enable automatic detection of the
cgroup driver as an alpha feature. See [systemd cgroup driver](#systemd-cgroup-driver)
for more details.
-->
在 Kubernetes v1.28 中,你可以启用 Cgroup 驱动程序的自动检测的 Alpha 级别特性。
详情参阅 [systemd cgroup 驱动](#systemd-cgroup-driver)

<!--
For CRI-O, the CRI socket is `/var/run/crio/crio.sock` by default.
-->
Expand Down

0 comments on commit 6d29856

Please sign in to comment.