libbpf / ci

BPF CI
Other
10 stars 23 forks source link

rootfs: fix foreign arch #56

Closed chantra closed 1 year ago

chantra commented 1 year ago

An update in upstream cause a binary on the foreign platform to be executed, which in turned caused the rootfs creation to fail with something like:

chroot: failed to run command '/bin/true': Exec format error

debootstrap can handle that natively by building the image in 2 steps. 1) download the packages, verify, and extract them inside the chroot 2) running a second stage that unpack and configure them.

Before the second stage, we copy qemu-${foreign_arch}-static into the chroot, allowing the native binaries to run properly.

After this fix, the rootfs images could be built.

Fixed #55

chantra commented 1 year ago

addressed the comments.