From 341bbeaf947b5073e6c7839c726c798cae077417 Mon Sep 17 00:00:00 2001 From: zhuzhenghao Date: Fri, 6 Jan 2023 14:06:44 +0800 Subject: [PATCH] [zh-cn] Sync field-selector.md with en page --- .../working-with-objects/field-selectors.md | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/content/zh-cn/docs/concepts/overview/working-with-objects/field-selectors.md b/content/zh-cn/docs/concepts/overview/working-with-objects/field-selectors.md index 09a85ee73b..2e9f2f0d0b 100644 --- a/content/zh-cn/docs/concepts/overview/working-with-objects/field-selectors.md +++ b/content/zh-cn/docs/concepts/overview/working-with-objects/field-selectors.md @@ -10,7 +10,7 @@ weight: 70 --> “字段选择器(Field selectors)”允许你根据一个或多个资源字段的值 [筛选 Kubernetes 资源](/zh-cn/docs/concepts/overview/working-with-objects/kubernetes-objects)。 @@ -29,18 +29,15 @@ This `kubectl` command selects all Pods for which the value of the [`status.phas ```shell kubectl get pods --field-selector status.phase=Running ``` - + {{< note >}} + 字段选择器本质上是资源“过滤器(Filters)”。默认情况下,字段选择器/过滤器是未被应用的, 这意味着指定类型的所有资源都会被筛选出来。 -这使得以下的两个 `kubectl` 查询是等价的: +这使得 `kubectl get pods` 和 `kubectl get pods --field-selector ""` 这两个 `kubectl` 查询是等价的。 -```shell -kubectl get pods -kubectl get pods --field-selector "" -``` {{< /note >}}