archzfs / archzfs-ci

Automated testing and deployment for archzfs using buildbot
http://ci.archzfs.com
GNU General Public License v2.0
5 stars 4 forks source link

btrfs not present in worker image #17

Open rearden888 opened 7 months ago

rearden888 commented 7 months ago

Two weeks ago, when I built the containers, everything worked fine. Containers build, builders worked, everything went fine. I went to transplant the service to my better home server and the builders were failing with the following error:

==== Building zfs-dkms...
==== Cleaning up work files...
Running command:
find /worker/all/build/packages/dkms/zfs-dkms \( -iname "*.log" -o -iname "*.pkg.tar.zst*" -o -iname "*.src.tar.gz" \) -print -exec rm -rf {} \; 
Output: 
Command returned: 0
Running command:
rm -rf  */src 
Output: 
Command returned: 0
Running command:
rm -rf */*.tar.gz 
Output: 
Command returned: 0
Running command:
cd "/worker/all/build/packages/dkms/zfs-dkms" && ccm64 s 
Output: 
----> No buildroot has been created so making one now...
/usr/sbin/mkarchroot: line 80: btrfs: command not found
==> ERROR: Couldn't create subvolume for '/scratch/.buildroot/root'
Command returned: 1
==== ERROR: A problem occurred building the package
~~~~ DEBUG: trap_exit: args $?=0
==== Sun Feb 25 22:29:32 UTC 2024 :: EXIT

Solution:

Added btrfs-progs to the first pacman line in the Dockerfile for the worker image, rebuilt the containers, and they worked fine. Not sure if something changed in the underlying arch base devel image. I couldn't find any indication if that actually happened to that base image. It could be a new requirement from clean-chroot manager maybe, too.

I wanted to post here before sending a PR in case the preferred solution involved something different.

minextu commented 7 months ago

Hmm interesting. I wonder if this is related to the host system using btrfs and the docker container seeing that / trying to make use of it

rearden888 commented 7 months ago

I'm not sure, it certainly could be something like that; however, I built the containers on a btrfs test system on the 21st, and they worked fine. When I tried to rebuild them on one of my main servers (also btrfs) over the weekend (on the 25th), after building when I tried to run a builder, it failed for the missing btrfs executable, which is what led me to think it was a change in the underlying base image, but I'm not particularly experienced with building containers and all the implications of building docker containers.