website icon indicating copy to clipboard operation
website copied to clipboard

Confusing paragraph in Labels and Selectors concept

Open thebaultyoann opened this issue 1 year ago • 3 comments

https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#equality-based-requirement

In the documentation, we have this statement: One usage scenario for equality-based label requirement is for Pods to specify node selection criteria. For example, the sample Pod below selects nodes with the label **"accelerator=nvidia-tesla-p100"**.

While an example just after doesn't use this, but instead ** accelerator: nvidia-tesla-p100`**

apiVersion: v1 kind: Pod metadata: name: cuda-test spec: containers: - name: cuda-test image: "registry.k8s.io/cuda-vector-add:v0.1" resources: limits: nvidia.com/gpu: 1 nodeSelector: accelerator: nvidia-tesla-p100

thebaultyoann avatar Jul 30 '24 12:07 thebaultyoann

/retitle Confusing paragraph in Labels and Selectors concept

We could edit the existing text, eg:

 One usage scenario for equality-based label requirement is for Pods to specify
-node selection criteria. For example, the sample Pod below selects nodes with
-the label "`accelerator=nvidia-tesla-p100`".
+node selection criteria. For example, the sample Pod below selects all nodes
+where the `accelerator` label exists and is set to `nvidia-tesla-p100`.

Although a narrow tweak is helpful, we'd welcome a wider revision of the entire page to align it with the documentation style guide.

/language en /priority backlog /triage accepted /help

sftim avatar Jul 30 '24 13:07 sftim

@sftim: This request has been marked as needing help from a contributor.

Guidelines

Please ensure that the issue body includes answers to the following questions:

  • Why are we solving this issue?
  • To address this issue, are there any code changes? If there are code changes, what needs to be done in the code and what places can the assignee treat as reference points?
  • Does this issue have zero to low barrier of entry?
  • How can the assignee reach out to you for help?

For more details on the requirements of such an issue, please see here and ensure that they are met.

If this request no longer meets these requirements, the label can be removed by commenting with the /remove-help command.

In response to this:

/retitle Confusing paragraph in Labels and Selectors concept

We could edit the existing text, eg:

One usage scenario for equality-based label requirement is for Pods to specify
-node selection criteria. For example, the sample Pod below selects nodes with
-the label "`accelerator=nvidia-tesla-p100`".
+node selection criteria. For example, the sample Pod below selects all nodes
+labelled `accelerator: nvidia-tesla-p100`.

Although a narrow tweak is helpful, we'd welcome a wider revision of the entire page to align it with the documentation style guide.

/language en /priority backlog /triage accepted /help

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

k8s-ci-robot avatar Jul 30 '24 13:07 k8s-ci-robot

/assign

kundan2707 avatar Jul 30 '24 17:07 kundan2707

Looks like PR https://github.com/kubernetes/website/pull/47320 has merged with the requested fix for this issue. We can close this issue now. (cc @kundan2707)

/close

steve-hardman avatar Jul 31 '24 01:07 steve-hardman

@steve-hardman: Closing this issue.

In response to this:

Looks like PR https://github.com/kubernetes/website/pull/47320 has merged with the requested fix for this issue. We can close this issue now. (cc @kundan2707)

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

k8s-ci-robot avatar Jul 31 '24 01:07 k8s-ci-robot