Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an Alpine variant. #107

Closed
wants to merge 4 commits into from
Closed

Add an Alpine variant. #107

wants to merge 4 commits into from

Conversation

shouze
Copy link

@shouze shouze commented Feb 25, 2016

Fixes #46.

Because of alpine libmusl we have to compile nodejs, we can't simply download & use the official binary tarballs.

This PR is inspired from https://github.com/mhart/alpine-node (except node wasn't compiled like official binary distributions are, with the small-icu option.)

@Starefossen
Copy link
Member

Thanks, but

@nodejs/docker do not merge this yet. There is long discussion and work going on to setup testing for Node.js on alpine linux and also to provide official binaries for Alpine Linux for stability and integrity purposes.

@shouze
Copy link
Author

shouze commented Feb 25, 2016

@Starefossen would be good news to provide official binaries. About stability what do you have in mind? Some libmusl issues?

@Starefossen
Copy link
Member

With stability I am mostly referring to making sure the test suite is fully passing on Alpine Linux. We are also working closely with Alpine Linux maintainers on this.

@retrohacker
Copy link
Contributor

Thanks for this @shigeki 😄

As @Starefossen mentioned, we have been working towards being able to officially support Alpine.

The issue stems from the fact the Node.js project doesn't officially support Alpine, so no testing is performed against it. Previous explorations with slimmed down Linux distributions has show that the binary works most of the time, but behaves unexpectedly in some edge cases. (if memory serves, I've personally had problems with the Linux command getaddrinfo not playing nicely with libc)

The @nodejs/docker team doens't have to take on the responsibility of owning tests for the other Docker images since they are tested upstream. Alpine is a different story.

We have quite a lot in place to get testing working (smoke tests, a testing framework, etc). The big piece that is missing right now is having the time to get Jenkins setup and configured to run our tests.

@shouze
Copy link
Author

shouze commented Feb 25, 2016

@retrohacker thx for the feedback. BTW, I've updated the Dockerfile if it can help. About Jenkins tell me if I can help on it, or moving tests to something like travis for example if more convenient.

One of the major issue with alpine (but not only) ATM seems to be the snapshot feature (rel to nodejs/node#4212).

About things like getaddrinfo you're right, libmusl is the big piece of replacement in alpine so it need to pay attention (for example dns search in resolv.conf still not supported in alpine 3.3 but fixed in incoming alpine edge).

I'm almost done to have node 5.7.0 automated build on docker hub: https://hub.docker.com/r/rezzza/docker-node/tags/

So I give it a try tomorrow on one of our pretty complete projects (https://verylastroom.com/fr/home) & I will be able to tell more about potential issues.

Sébastien HOUZÉ and others added 4 commits February 26, 2016 04:39
Since we delete the cache at the end we can just drop the `--no-cache`
and avoid downloadind the APKINDEX for every `apk` run.

We also autodetect the runtime dependencies using `scanelf` and protect
them using `--virtual`.
Improve download and install of dependencies
@shouze
Copy link
Author

shouze commented Mar 1, 2016

@ncopa @Starefossen @retrohacker I close this PR as at some time official alpine binary distribution will come. I maintain a https://github.com/rezzza/docker-node which won't be a fork anymore of https://github.com/nodejs/docker-node.

@shouze shouze closed this Mar 1, 2016
@shouze shouze deleted the issue/46 branch March 1, 2016 13:39
@chorrell chorrell mentioned this pull request Apr 25, 2016
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.

None yet

4 participants