CICD-194 · Check free storage before building
Encyclopedia · CI diagnostics and evidence · All snippets
Previous · CICD-193 · Next · CICD-195
1. Where it fits
- Placement Bash run step following checkout, or equivalent lab terminal.
- Prerequisites authorized fixture run and sanitized evidence location.
- Platforms local-linux, github-actions, gitea-actions.
2. Copy the snippet
bash
df -Pk .
test "$(df -Pk . | awk 'NR==2 {print $4}')" -ge 10485763. How it works
The shell predicate makes the expected state explicit and returns a nonzero status when it is not satisfied.
4. Verify the result
Require at least 1 GiB free on the current workspace filesystem.
Validation syntax-validated (Bash parse). Status definitions.