live-image: install stage tools and fail loudly if any are missing
The live image was still carrying the Phase 2 package list, so SMART, CPUStress, and Network each hit a LookPath miss and returned pass-with-skip. A run that skipped every real check still ended in "completed" — nothing on the report said the image was broken. Add smartmontools, stress-ng, fio, iperf3, lshw, lm-sensors, e2fsprogs, and util-linux to mkosi.conf. Flip the three stages from skip-pass to fail when their binary is missing so any future packaging regression blocks the run instead of whispering past it. Legitimate "no hardware" skips (no GPU, no hwmon, no disks, non-destructive) are untouched. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -20,11 +20,15 @@ import (
|
||||
// pages for the full duration, which is the Phase 4 health bar.
|
||||
func CPUStress(ctx context.Context, d Deps) Outcome {
|
||||
if _, err := exec.LookPath("stress-ng"); err != nil {
|
||||
d.Warn("CPUStress: stress-ng not found in PATH — skipping stage")
|
||||
// The live image ships stress-ng; absence is a packaging defect,
|
||||
// not a benign local-dev scenario. Fail loudly so a regression
|
||||
// in the image doesn't silently pass runs.
|
||||
d.Error("CPUStress: stress-ng not found in PATH — live image is missing required tool")
|
||||
return Outcome{
|
||||
Passed: true,
|
||||
Summary: "skipped (stress-ng missing)",
|
||||
Extras: map[string]any{"skipped": true, "reason": "stress_ng_missing"},
|
||||
Passed: false,
|
||||
Message: "stress-ng binary missing from live image",
|
||||
Summary: "failed (stress-ng missing)",
|
||||
Extras: map[string]any{"reason": "stress_ng_missing"},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user