From 3201e8404561026f4d6cc05fcab46ca3a0461663 Mon Sep 17 00:00:00 2001 From: ut003055 Date: Fri, 20 May 2022 10:35:58 +0800 Subject: [PATCH 1/4] translate binding page --- .../cluster-resources/binding-v1.md | 228 ++++++++++++++++++ 1 file changed, 228 insertions(+) create mode 100644 content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md diff --git a/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md b/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md new file mode 100644 index 0000000000..a76cc3071a --- /dev/null +++ b/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md @@ -0,0 +1,228 @@ +--- +api_metadata: + apiVersion: "v1" + import: "k8s.io/api/core/v1" + kind: "Binding" +content_type: "api_reference" +description: "Binding 即将一个对象与另一个对象联系起来;例如,一个 pod 被调度程序绑定到一个节点。" +title: "Binding" +weight: 9 +auto_generated: true +--- + + + +`apiVersion: v1` + +`import "k8s.io/api/core/v1"` + + +## Binding {#Binding} + +Binding 即将一个对象与另一个对象联系起来;例如,一个 pod 被调度程序绑定到一个节点。1.7已弃用,请使用 pods 的 bindings 子资源。 +
+ +- **apiVersion**: v1 + + +- **kind**: Binding + + +- **metadata** (}}">ObjectMeta) + + 标准对象的元数据 更多信息: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + +- **target** (}}">ObjectReference), 必需的 + + 要绑定到标准对象的目标对象。 + +## Operations {#Operations} + +
+ + +### `创建` 创建一个 Binding + +#### HTTP 请求 + +POST /api/v1/namespaces/{namespace}/bindings + +#### 参数 + + +- **namespace** (**在路径上**): string, 必需的 + + }}">namespace + + +- **body**: }}">Binding, 必需的 + + +- **dryRun** (**查询字符串**): string + + }}">dryRun + + +- **fieldManager** (**查询字符串**): string + + }}">fieldManager + + + + +- **fieldValidation** (**查询字符串**): string + + }}">fieldValidation + + +- **pretty** (**查询字符串**): string + + }}">pretty + + +#### 响应 + +200 (}}">Binding): OK + +201 (}}">Binding): Created + +202 (}}">Binding): Accepted + +401: Unauthorized + + +### `create` 创建Pod的绑定 + +#### HTTP 请求 + +POST /api/v1/namespaces/{namespace}/pods/{name}/binding + +#### 参数 + +- **name** (*在路径内*): string, 必需的 + + Binding 的名称 + +- **namespace** (*在路径内*): string, 必需的 + + }}">namespace + +- **body**: }}">Binding, 必需的 + + +- **dryRun** (**查询字符串**): string + + }}">dryRun + + +- **fieldManager** (**查询字符串**): string + + }}">fieldManager + +- **fieldValidation** (**查询字符串**): string + + }}">fieldValidation + +- **pretty** (**查询字符串**): string + + }}">pretty + +#### 响应 + +200 (}}">Binding): OK + +201 (}}">Binding): Created + +202 (}}">Binding): Accepted + +401: Unauthorized From 8fe03cc9fd08e908e19b7b97b77485b5c5da5fb5 Mon Sep 17 00:00:00 2001 From: ut003055 Date: Fri, 20 May 2022 14:19:53 +0800 Subject: [PATCH 2/4] Modify according to review --- .../kubernetes-api/cluster-resources/binding-v1.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md b/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md index a76cc3071a..78d827364f 100644 --- a/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md +++ b/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md @@ -4,7 +4,7 @@ api_metadata: import: "k8s.io/api/core/v1" kind: "Binding" content_type: "api_reference" -description: "Binding 即将一个对象与另一个对象联系起来;例如,一个 pod 被调度程序绑定到一个节点。" +description: "Binding 将一个对象与另一个对象联系起来; 例如,一个 Pod 被调度程序绑定到一个节点。" title: "Binding" weight: 9 auto_generated: true @@ -30,7 +30,7 @@ guide. You can file document formatting bugs against the -Binding 即将一个对象与另一个对象联系起来;例如,一个 pod 被调度程序绑定到一个节点。1.7已弃用,请使用 pods 的 bindings 子资源。 +Binding 将一个对象与另一个对象联系起来; 例如,一个 Pod 被调度程序绑定到一个节点。1.7 已弃用,请使用 Pod 的 Binding 子资源。
- **apiVersion**: v1 @@ -47,7 +47,7 @@ Binding 即将一个对象与另一个对象联系起来;例如,一个 pod 被 The target object that you want to bind to the standard object. --> - 标准对象的元数据 更多信息: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + 标准对象的元数据, 更多信息: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata - **target** (}}">ObjectReference), 必需的 @@ -66,7 +66,7 @@ POST /api/v1/namespaces/{namespace}/bindings #### Parameters --> -### `创建` 创建一个 Binding +### `create` 创建一个 Binding #### HTTP 请求 @@ -150,7 +150,7 @@ POST /api/v1/namespaces/{namespace}/bindings POST /api/v1/namespaces/{namespace}/pods/{name}/binding --> -### `create` 创建Pod的绑定 +### `create` 创建 Pod 的绑定 #### HTTP 请求 From 603dea2552148f339f924361d5aaffb6247dd4cb Mon Sep 17 00:00:00 2001 From: ut003055 Date: Mon, 23 May 2022 10:30:46 +0800 Subject: [PATCH 3/4] modify --- .../cluster-resources/binding-v1.md | 34 ++++++++----------- 1 file changed, 14 insertions(+), 20 deletions(-) diff --git a/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md b/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md index 78d827364f..66593b909e 100644 --- a/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md +++ b/content/zh/docs/reference/kubernetes-api/cluster-resources/binding-v1.md @@ -10,17 +10,6 @@ weight: 9 auto_generated: true --- - - `apiVersion: v1` `import "k8s.io/api/core/v1"` @@ -30,7 +19,8 @@ guide. You can file document formatting bugs against the -Binding 将一个对象与另一个对象联系起来; 例如,一个 Pod 被调度程序绑定到一个节点。1.7 已弃用,请使用 Pod 的 Binding 子资源。 +Binding 将一个对象与另一个对象联系起来; 例如,一个 Pod 被调度程序绑定到一个节点。 +已在 1.7 版本弃用,请使用 Pod 的 binding 子资源。
- **apiVersion**: v1 @@ -42,18 +32,22 @@ Binding 将一个对象与另一个对象联系起来; 例如,一个 Pod 被 - **metadata** (}}">ObjectMeta) + 标准对象的元数据, 更多信息: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + - 标准对象的元数据, 更多信息: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata -- **target** (}}">ObjectReference), 必需的 +- **target** (}}">ObjectReference), 必需 要绑定到标准对象的目标对象。 - + +## 操作 {#operations}
@@ -82,12 +76,12 @@ POST /api/v1/namespaces/{namespace}/bindings - **body**: }}">Binding, required --> -- **namespace** (**在路径上**): string, 必需的 +- **namespace** (**路径参数**): string, 必需 }}">namespace -- **body**: }}">Binding, 必需的 +- **body**: }}">Binding, 必需 #### 参数 -- **name** (*在路径内*): string, 必需的 +- **name** (**路径参数**): string, 必需 Binding 的名称 -- **namespace** (*在路径内*): string, 必需的 +- **namespace** (**路径参数**): string, 必需 }}">namespace -- **body**: }}">Binding, 必需的 +- **body**: }}">Binding, 必需 -- **dryRun** (**查询字符串**): string +- **dryRun** (**查询参数**): string }}">dryRun -- **fieldManager** (**查询字符串**): string +- **fieldManager** (**查询参数**): string }}">fieldManager @@ -115,12 +115,12 @@ POST /api/v1/namespaces/{namespace}/bindings }}">pretty --> -- **fieldValidation** (**查询字符串**): string +- **fieldValidation** (**查询参数**): string }}">fieldValidation -- **pretty** (**查询字符串**): string +- **pretty** (**查询参数**): string }}">pretty @@ -194,20 +194,20 @@ POST /api/v1/namespaces/{namespace}/pods/{name}/binding }}">pretty --> -- **dryRun** (**查询字符串**): string +- **dryRun** (**查询参数**): string }}">dryRun -- **fieldManager** (**查询字符串**): string +- **fieldManager** (**查询参数**): string }}">fieldManager -- **fieldValidation** (**查询字符串**): string +- **fieldValidation** (**查询参数**): string }}">fieldValidation -- **pretty** (**查询字符串**): string +- **pretty** (**查询参数**): string }}">pretty