Dear VyOS community,
I have search in this forum for a similar error, that have been a few reports on similar error, however the issue has rised again it seams.
Following the build steps in the official docs but no matter what I do, it seams to fail hard, and the log yields nothing of the error.
Note that I try to change between arm64.
I am running the docker container on Ubuntu 24.04 noble, Kernel: x86_64 Linux 6.8.0-49-generic
EDIT:
I tried to fix the script, but i am unable to resolve the problem.
But I have identified the problem to be in the python script scripts/image-build/build-vyos-image
.
I just hope someone more experienced then me could solve this issue.
EDIT:
I removed the workaround, because it did not work as expected.
# Line 670
cmd("lb build 2>&1")
Steps to reproduce:
# Clone the repo
$ git clone -b current --single-branch https://github.com/vyos/vyos-build && cd vyos-build
# For VyOS 1.5 (circinus,current)
$ sudo make clean
$ sudo ./build-vyos-image generic --architecture amd64 --build-by "[email protected]"
$ docker pull vyos/vyos-build:current # For VyOS 1.5 rolling release
$ docker build -t vyos/vyos-build:current docker # For VyOS 1.5 rolling release
Running the build using the docker by enter interactive mode:
$ sudo docker run --rm -it --privileged -v $(pwd):/vyos -w /vyos vyos/vyos-build:current bash
And trying to start the build:
$ sudo ./build-vyos-image generic --architecture arm64 --build-by "[email protected]"
Error:
W: Failure trying to run: chroot "/vyos/build/chroot" /bin/true
W: See /vyos/build/chroot/debootstrap/debootstrap.log for details
E: An unexpected failure occurred, exiting...
Traceback (most recent call last):
File "/vyos/./build-vyos-image", line 670, in <module>
cmd("lb build 2>&1")
File "/vyos/scripts/image-build/utils.py", line 84, in cmd
raise OSError(f"Command '{command}' failed")
OSError: Command 'lb build 2>&1' failed
vyos_bld@b20b413bfea0:/vyos$
From the log file:
# build/chroot/debootstrap/debootstrap.log
chroot: failed to run command ‘/bin/true’: Exec format error
Source:
https://docs.vyos.io/en/latest/contributing/build-vyos.html