Commit 76bf9df
committed
ci: reduce memory and disk usage in test-convert jobs
- Remove --tmpfs /tmp from the test container. The work directory created
by cryptpilot-convert.sh inside /tmp can reach ~40 GB (rootfs.img +
work qcow2), far exceeding the 7 GB RAM available on ubuntu-latest
runners. Without the tmpfs flag /tmp uses Docker overlay storage backed
by host disk, eliminating the OOM that caused encrypted test cases to
fail after ~53 minutes.
- Delete the pulled test docker image immediately after extracting the
qcow2 file, freeing several GB of Docker layer cache.
- In run_test_case, delete input.qcow2 and SOURCE_IMAGE right after
conversion succeeds. output.qcow2 is a standalone image and does not
reference these files, so they are safe to remove before the verify
and QEMU boot steps. This reclaims ~20.5 GB of disk space during the
most resource-intensive part of the test.
- Add a disk/memory reporting step (df -h && free -h) before starting
the test container to aid future debugging.1 parent 8fd33a6 commit 76bf9df
2 files changed
Lines changed: 16 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
212 | 212 | | |
213 | 213 | | |
214 | 214 | | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
215 | 220 | | |
216 | 221 | | |
217 | 222 | | |
| |||
222 | 227 | | |
223 | 228 | | |
224 | 229 | | |
225 | | - | |
226 | 230 | | |
227 | 231 | | |
228 | 232 | | |
| |||
273 | 277 | | |
274 | 278 | | |
275 | 279 | | |
276 | | - | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
277 | 283 | | |
278 | 284 | | |
279 | 285 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
624 | 624 | | |
625 | 625 | | |
626 | 626 | | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
627 | 633 | | |
628 | 634 | | |
629 | 635 | | |
| |||
634 | 640 | | |
635 | 641 | | |
636 | 642 | | |
637 | | - | |
| 643 | + | |
638 | 644 | | |
639 | | - | |
| 645 | + | |
640 | 646 | | |
641 | 647 | | |
642 | 648 | | |
| |||
0 commit comments