Repository navigation
Description
Problem
The GPU placement warning of devops k8s deploy-stack tells a person to label a node by hand. gpu_node_without_total and gpu_node_total_not_accepted (src/devops_cli/lang/en/messages.py) print kubectl label node <node> nvidia.com/gpu.total-vram-gib=<N>Gi.
On the homelab, Node Feature Discovery now sets nvidia.com/gpu.total-vram-gib and nvidia.com/gpu.architecture from a NodeFeatureRule of Application nvidia-device-plugin (dan-petty/homelab#551, pull request 569). NFD writes the value of the rule again, so a label set by hand does not last. The fix for a total that no tier lists is a change of the tier list in llm/profiles/ollama-profiles.yaml.
The same rule copies GPU Feature Discovery's nvidia.com/gpu.family into nvidia.com/gpu.architecture only because CONST_K8S_GPU_ARCHITECTURE_LABEL names that key (_newest_architecture in src/devops_cli/k8s/gpu_thresholds.py, gpu_placement.py). GFD's family names are the names of CONST_K8S_GPU_ARCHITECTURES.
Change
- Make the two warnings name the tier list in git, not a
kubectl labelcommand. - Optional: read
nvidia.com/gpu.family, so the environment can drop the copied label.
Done when
- No message of
deploy-stacktells a person to set a GPU label by hand.
Source
Alternatives check of 2026-11-27: none.
Tool: none found.
Reason: Searches returned only NVIDIA device-plugin and GPU-operator images, none of which changes a project's own warning text; the need is an edit of two message strings plus optionally reading an existing NFD label, so no external tool covers it.
Lacks:
- No tool rewrites the project's own warning messages
- Node label sources are already NFD rules in the homelab repo
- Tier list edit in ollama-profiles.yaml is project-specific
Proposed design
Problem statement
The GPU placement warnings of devops k8s deploy-stack tell a person to set a node label by hand. Node Feature Discovery writes that label again from a NodeFeatureRule, so a hand-set label does not last. The two warnings must name the GPU tier list in git instead of a kubectl label node command. The optional read of the GPU family label is a separate part and is deferred.
Acceptance criteria
Requirement: GPU node without total names the tier list
The gpu_node_without_total warning SHALL name llm/profiles/ollama-profiles.yaml as the place to add a GPU tier.
Scenario: Warning for a node with no GPU total
- WHEN The test at
tests/commands/k8s/test_k8s_gpu_placement.pyformatsgpu_node_without_totalfor a node with nonvidia.com/gpu.total-vram-giblabel. - THEN The formatted text holds
llm/profiles/ollama-profiles.yamland holds nokubectl label node.
Requirement: GPU node total not accepted names the tier list
The gpu_node_total_not_accepted warning SHALL name llm/profiles/ollama-profiles.yaml as the place to change the GPU tier list.
Scenario: Warning for a GPU total that no tier lists
- WHEN The test at
tests/commands/k8s/test_k8s_gpu_placement.pyformatsgpu_node_total_not_acceptedfor a node whose total is not in the tier list. - THEN The formatted text holds
llm/profiles/ollama-profiles.yamland holds nokubectl label node.
Requirement: GPU placement warnings hold no manual label command
Every GPU placement warning of devops k8s deploy-stack MUST NOT hold the text kubectl label node.
Scenario: GPU placement warning catalog
- WHEN The test at
tests/commands/k8s/test_k8s_gpu_placement.pyformats each attribute of the modulesrc/devops_cli/lang/en/messages.pywhose name starts withgpu_node_. - THEN No formatted attribute holds
kubectl label node.
Existing Tool Considered
The alternatives check of 2026-11-27 in the issue body gives the verdict none and names no tool. It holds what no tool covers. No open, maintained tool or library covers the need, because no tool rewrites the warning text of the project itself. The change edits two strings in src/devops_cli/lang/en/messages.py. The written cost to build, keep and fix that code until a tool matches it is about 5,000 tokens and 45 minutes.
Key questions
- Where do the two GPU placement warnings live, and which module formats them?:
gpu_node_without_totalis atsrc/devops_cli/lang/en/messages.py:926.gpu_node_total_not_acceptedis atsrc/devops_cli/lang/en/messages.py:930. The modulesrc/devops_cli/k8s/gpu_placement.pyformats both for the placement report. [sources: src/devops_cli/lang/en/messages.py:926, src/devops_cli/lang/en/messages.py:930, src/devops_cli/k8s/gpu_placement.py] - Which source should the two GPU placement warnings name for a GPU total that no tier lists?: The warnings name the GPU tier list
llm/profiles/ollama-profiles.yaml. A person adds or changes the tier there. The warning holds nokubectl label nodecommand. (best practice) [sources: src/devops_cli/lang/en/messages.py:926, src/devops_cli/lang/en/messages.py:930]- Chosen: Name the tier list in git. Node Feature Discovery writes the GPU labels again from a NodeFeatureRule, so a hand-set label does not last. The tier list is the durable source.
- Rejected: Keep the
kubectl label nodecommand. The NodeFeatureRule of the homelab writes the label again. The command tells a person to do work that does not last. - Rejected: Name no path and point at the environment tier list. The body asks the warnings to name the tier list. A path is actionable and a test can check it.
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Activity
dan-petty commentedon Nov 27, 2026
Both concern k8s GPU node labeling, but #7252 removes a DaemonSet while the candidate changes warning text in deploy-stack.devops-cli-service commentedon Nov 27, 2026
The result in the alternatives block of the issue body changed. Before this check: no check. A person decides what the new result means for the item.
Searches (7)
Searches run:
devops-cli-service commentedon Nov 28, 2026
Next step: the stage job writes the plan of the item. See the section Proposed design of the body.
dan-petty commentedon Nov 28, 2026
Returned to New per Rule 2 (cannot be built as specified):
The refined acceptance criteria for the optional
nvidia.com/gpu.familyfallback require passing a node label map (nvidia.com/gpu.family/nvidia.com/gpu.architecture) directly to_newest_architectureintests/commands/k8s/test_k8s_gpu_placement.pyand returning the architecture/family string from that map.In the codebase:
_newest_architecture(template: dict[str, Any]) -> strlives insrc/devops_cli/k8s/gpu_thresholds.py:116, takes a DaemonSet manifest template (readingspec.template.spec.affinity.nodeAffinity.requiredDuringSchedulingIgnoredDuringExecution.nodeSelectorTerms), and returns the newest accepted architecture value acrossmatchExpressions.src/devops_cli/k8s/gpu_placement.pyhas no_newest_architecturefunction and evaluates DaemonSetmatchExpressionsverbatim against node labels (accepts); treatingnvidia.com/gpu.familyas satisfying anvidia.com/gpu.architectureselector would misreport Kubernetes scheduling while manifests still requirenvidia.com/gpu.architecture.The warning message updates (
gpu_node_without_totalandgpu_node_total_not_acceptedinsrc/devops_cli/lang/en/messages.py) are ready to implement once the optionalnvidia.com/gpu.familycriteria are scoped against the realgpu_thresholds._newest_architecture(template)/gpu_placementsignatures (or dropped to keep only the warning fix).devops-cli-service commentedon Nov 28, 2026
Next step: the stage job writes the plan of the item. See Moved to new items in the section Proposed design of the body.
devops-cli-service commentedon Nov 29, 2026
Released in v0.243.1: https://github.com/dan-petty/devops-cli/releases/tag/v0.243.1
devops-cli-service commentedon Nov 29, 2026
Live since 2026-11-29 03:13 UTC