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
When using an Alpine Linux based Docker image (i.e., node:alpine) and trying to invoke git-cliff via the NPM installation option, one is greeted with an ENOENT error as node_modules/git-cliff-linux-x64/bin/git-cliff is invoked.
If you try installing gcompat or libc6-compat via apk in an attempt to resolve this, the error changes from ENOENT to symbol not found.
I've tried various combinations of gcompat, libc6-compat, libstdc++, etc. and cannot get it working in Alpine Linux. The minute I switch to a non-Alpine variant, such as node:22-slim, it "just works".
Steps To Reproduce
In a new, empty folder, initialize a basic Git repo:
git init
In the same folder, create a new Dockerfile
In the Dockerfile, add the following:
FROM node:alpine
WORKDIR /app
COPY .git ./.git
RUN apk update && apk upgrade
RUN npm init -y \
&& npm install git-cliff
RUN npx git-cliff -o CHANGELOG.md
$ ldd ./node_modules/git-cliff-linux-x64/bin/git-cliff
/lib64/ld-linux-x86-64.so.2 (0x7c9ffb4b0000)
libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x7c9ffa640000)
librt.so.1 => /lib64/ld-linux-x86-64.so.2 (0x7c9ffb4b0000)
libpthread.so.0 => /lib64/ld-linux-x86-64.so.2 (0x7c9ffb4b0000)
libm.so.6 => /lib64/ld-linux-x86-64.so.2 (0x7c9ffb4b0000)
libdl.so.2 => /lib64/ld-linux-x86-64.so.2 (0x7c9ffb4b0000)
libc.so.6 => /lib64/ld-linux-x86-64.so.2 (0x7c9ffb4b0000)
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: __snprintf_chk: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: __res_init: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: __register_atfork: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: __memcpy_chk: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: posix_fallocate64: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: __vsnprintf_chk: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: __strncpy_chk: symbol not found
Error relocating ./node_modules/git-cliff-linux-x64/bin/git-cliff: gnu_get_libc_version: symbol not found
The binaries that are being installed via NPM package is built in the CI using the ubuntu-22.04 runner. Maybe there is a incompatibility between the glibc version in the Docker image and the binary?
Unfortunately there is no MUSL binaries built in the CI right now. See the full build matrix here.
Is there an existing issue for this?
Description of the bug
When using an Alpine Linux based Docker image (i.e.,
node:alpine
) and trying to invoke git-cliff via the NPM installation option, one is greeted with anENOENT
error asnode_modules/git-cliff-linux-x64/bin/git-cliff
is invoked.If you try installing
gcompat
orlibc6-compat
via apk in an attempt to resolve this, the error changes fromENOENT
tosymbol not found
.I've tried various combinations of
gcompat
,libc6-compat
,libstdc++
, etc. and cannot get it working in Alpine Linux. The minute I switch to a non-Alpine variant, such asnode:22-slim
, it "just works".Steps To Reproduce
Dockerfile
docker build --progress=plain .
Dockerfile
so that we install gcompat before running our NPM commandsdocker build --progress=plain .
and observe a slightly different build failure:Expected behavior
I expect the Docker image to build without any errors, as it would if I was using a non-Alpine Linux base image.
Screenshots / Logs
No response
Software information
node:alpine
(Docker Hub),node:22-alpine
(Docker Hub)Additional context
No response
The text was updated successfully, but these errors were encountered: