CICD-441 · GPU availability detection
Encyclopedia · GPU and inference infrastructure · All snippets
Previous · CICD-440 · Next · CICD-442
1. Where it fits
- Placement runner probe.
- Prerequisites dedicated GPU lab, approved images and model revision, fixed benchmark profile.
- Platforms local-linux, github-actions, gitea-actions.
2. Copy the snippet
bash
nvidia-smi --query-gpu=index,name,memory.total --format=csv,noheader
test "$(nvidia-smi --query-gpu=uuid --format=csv,noheader | wc -l)" -ge 13. How it works
nvidia-smi reports GPU identity and memory, then a second query checks that the enumerated list is nonempty. Measure inside the actual job environment.
4. Verify the result
Check inside the runner environment that will start the engine. Record the device type and count.
Validation syntax-validated (Bash parse). Status definitions.