-
Notifications
You must be signed in to change notification settings - Fork 333
Description
I'm encountering an issue when building multi-arch Docker images based on ruby:3.4.7-alpine.
Problem
Since the recent update to Alpine 3.23 (#520), building for linux/arm64 under QEMU emulation (in GitHub Actions) fails. APK package triggers crash with:
#7 [linux/arm64 2/2] RUN apk add --no-cache ca-certificates
#7 2.199 (1/1) Installing ca-certificates (20251003-r0)
#7 2.240 Executing busybox-1.37.0-r29.trigger
#7 2.244 * execve: No such file or directory
#7 2.246 ERROR: lib/apk/exec/busybox-1.37.0-r29.trigger: exited with error 127
#7 2.246 Executing ca-certificates-20251003-r0.trigger
#7 2.248 * execve: No such file or directory
#7 2.249 ERROR: lib/apk/exec/ca-certificates-20251003-r0.trigger: exited with error 127
#7 2.261 2 errors; 9 MiB in 22 packages
#7 ERROR: process "/dev/.buildkit_qemu_emulator /bin/sh -c apk add --no-cache ca-certificates" did not complete successfully: exit code: 2
This happens when installing a package that has post-install triggers, such as ca-certificates.
Reproduction
I have created a minimal reproduction repository:
https://github.com/ledermann/ruby-alpine-3.23-apk-repro
This is the failing workflow run:
https://github.com/ledermann/ruby-alpine-3.23-apk-repro/actions/runs/19952870438/job/57216316282
The Dockerfile is just this:
FROM ruby:3.4.7-alpine
RUN apk add --no-cache ca-certificatesPinning to ruby:3.4.7-alpine3.22 works as expected. The issue seems to be caused by changes in Alpine 3.23's busybox or apk-tools that are incompatible with QEMU.