Skip to content

Conversation

@pm47
Copy link
Member

@pm47 pm47 commented Mar 18, 2025

The Alpine base image causes systematic crash for some libsecp256k1 operations (secp256k1_der_parse_integer). JNI-related issues related to the use of musl instead of glibc are well documented.

The issue is fixed by switching alpine for ubuntu, which is glibc-based. Note that it makes the final image significantly larger (502MB vs 313MB).

The goal of using the JVM on docker was for compatibility with ARM. Once we support native ARM on Linux (#157), we could potentially move back to Alpine with native phoenixd, an even smaller footprint than before.

Fixes #159.

The Alpine base image causes systematic crash for some libsecp256k1
operations. JNI-related issues related to the use of `musl` instead of
`glibc` are well documented.

The issue is fixed by switching alpine for ubuntu, which is
`glibc`-based. Note that it makes the final image significantly larger
(502MB vs 313MB).

The goal of using the JVM on docker was for compatibility with ARM. Once
we support native ARM on Linux (#157), we could potentially move back to
Alpine with native phoenixd, an even smaller footprint than before.

Fixes #159.
@pm47 pm47 merged commit 1f8b03d into master Mar 18, 2025
@pm47 pm47 deleted the docker-remove-alpine branch March 18, 2025 14:47
pm47 added a commit that referenced this pull request May 12, 2025
This a follow-up to #161, specifically:
> The goal of using the JVM on docker was for compatibility with ARM. Once we support native ARM on Linux (#157), we could potentially move back to Alpine with native phoenixd, an even smaller footprint than before.

I didn't go with Alpine because it isn't glibc based and we could run into compat issues. Nevertheless, with Debian slim the image size has been reduced from 230MB to 40MB (-80%).

Cross-platform build:
```shell
docker buildx build --platform linux/amd64,linux/arm64 -t acinq/phoenixd:0.6.0 --push .docker
```

From now on the image will be published on docker hub: https://hub.docker.com/repository/docker/acinq/phoenixd/general.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

getting error after passing the seed to docker container

3 participants