[BUG] Fails to run on Alpine images
Describe the bug.
The CLI x86_64 tarball is dynamically linked against glibc and Alpine based images expects musl-compatible binaries.
Hence, when trying to create a Docker image based on alpine it fails to run with:
ld-linux-x86-64.so.2: /opt/asyncapi/bin/node: Not a valid dynamic program
When run ldd asyncapi:
/lib/ld-musl-x86_64.so.1: cannot load asyncapi: No such file or directory
Expected behavior
I would expect that I can run asyncapi cli on alpine distro.
Screenshots
How to Reproduce
Dockerfile:
FROM alpine:3.21
RUN apk update
RUN apk --no-cache add bash
# Install asyncapi-cli
ENV ASYNCAPI_VERSION="v2.16.5"
RUN wget --quiet -c -O- https://github.com/asyncapi/cli/releases/download/$ASYNCAPI_VERSION/asyncapi.tar.gz | tar -xz -C /opt
RUN ln -s /opt/asyncapi/bin/asyncapi /usr/local/bin/asyncapi
Docker run commands
docker build --platform linux/amd64 . -t imgdocker run img asyncapi
This also fails when installing glibc compatibility packages libc6-compat or gcompat.
🥦 Browser
None
👀 Have you checked for similar open issues?
- [x] I checked and didn't find similar issue
🏢 Have you read the Contributing Guidelines?
- [x] I have read the Contributing Guidelines
Are you willing to work on this issue ?
None
Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.
@AceTheCreator @chriptus13 Can I work on this Issue, I will start work once assigned. Estimated Time : One day
sure @Rustix69 go ahead give it a try
@Rustix69 do you have any update on this?
Please have a look the release is failing. https://github.com/asyncapi/cli/actions/runs/17151676406/job/48660192897
Please have a look the release is failing. https://github.com/asyncapi/cli/actions/runs/17151676406/job/48660192897
because in that action the install dependencies were failing because of wrong lock file !
It is still failing: https://github.com/asyncapi/cli/actions/runs/17618055890/job/50056387323
Just had a fix here recently: https://github.com/asyncapi/cli/pull/1848