You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
build(cpex): slim authbridge-cpex to musl/alpine on CPEX v0.2.0-alpha.2
The authbridge-cpex image was ~151 MB, dominated by the debian:trixie-slim
runtime base needed for the glibc FFI asset — the FFI binary itself was a small
part of the delta. Switch to the musl FFI asset + Alpine base and pin the
CPEX release that carries the size-first profile and the cedar small-stack fix.
Result: 151 MB -> ~42 MB (binary 38 MB -> 28 MB), full 9/9 hr-cpex scenarios
green on the musl image.
Dockerfile:
- CPEX_LIBC defaults to musl; runtime base debian:trixie-slim -> alpine:3.20
(same digest the proxy/lite images pin); builder golang:bookworm ->
golang:1.25-alpine + gcc/musl-dev for the CGO link.
- Pin the multi-arch *index* digest for golang:1.25-alpine, not a single-arch
sub-manifest: unlike the pure-Go images (CGO_ENABLED=0, which cross-compile),
this links a native-arch libcpex_ffi.a, so the builder must run on the target
arch. The amd64-only digest broke arm64 builds.
- Install libgcc in the runtime stage — the FFI links cedar/Rust unwinder
symbols (_Unwind_*) that glibc bases ship implicitly but Alpine does not.
- CGO_LDFLAGS drops -ldl (musl folds it into libc).
Dependencies:
- CPEX_FFI_VERSION v0.2.0-alpha.1 -> v0.2.0-alpha.2 (FFI ABI unchanged, stays 2).
- Go binding github.com/contextforge-org/cpex/go/cpex bumped to v0.2.0-alpha.2
in authlib and cmd/authbridge-cpex.
Signed-off-by: Frederico Araujo <frederico.araujo@ibm.com>
0 commit comments