run: copy artifacts with --sparse=never
On macOS, files copied on a bind mounted volume can be corrupted if the original is sparse. In particular, this can happen for the rootfs image. Setting --sparse=never
in the copy prevents this corruption.
The rootfs.ext2
resulting from the current buildroot.yaml
is not sparse so this change will only noticeably affect custom configurations.
In my case, the corruption was visible when building a custom rootfs with a 512 MiB image. The copied file ended up truncated at ~384 MiB and with a sparsity > 1.