Node.js backed by Busybox for really small image.
7.6K
DEPRICATION NOTICE
I'm abandoning this in favor of jmervine/mininode for newer version due to changes in Busybox which makes building things annoying. I will be added new versions there as they become available in Alpine's package manager. I've also included jmervine/miniiojs as part of this switch.
WARNING!!!
With the exception of
-fatvariants, which are much larger, these images don't containpython. As such,node-gypand therefore native extensions will not work.
This repository contains Dockerfile of Node.js running with Busybox (~28 MB virtual size) published to the public Docker Hub Registry.
> docker run --rm -ti jmervine/nodebox:<VERSIOM>
# node --version
v<VERSION>
0.12.6, 0.12.6-onbuild, 0.12.6-fat,
0.12, 0.12-onbuild, 0.12-fat,
latest, latest-onbuild, latest-fat0.12.5, 0.12.5-onbuild, 0.12.5-fat0.12.4, 0.12.4-onbuild, 0.12.4-fat0.12.3, 0.12.3-onbuild, 0.12.3-fat0.12.2, 0.12.2-onbuild, 0.12.2-fat0.12.0, 0.12.0-onbuild, 0.12.0-fat0.11.16, 0.11.16-onbuild, 0.11.16-fat0.11.14, 0.11.14-onbuild, 0.11.14-fat0.10.40, 0.10.40-onbuild, 0.10.40-fat,
0.10, 0.10-onbuild, 0.10-fat0.10.38, 0.10.38-onbuild, 0.10.38-fat0.10.36, 0.10.36-onbuild, 0.10.36-fat0.10.34, 0.10.34-onbuild, 0.10.34-fat0.10.32, 0.10.32-onbuild, 0.10.32-fat0.10.25, 0.10.25-onbuild, 0.10.25-fatAll versions support an -onbuild variant. This is based on the core nodejs docker image, and expects the following:
Dockerfile is in your project root along side your package.json.npm start.Example tree:
.
├── Dockerfile
├── app.js
└── package.json
Example Dockerfile:
FROM jmervine/nodebox:0.10.36-onbuild
# replace this with your application's default port
EXPOSE 8888
Fork this repo.
To add a new version, simply create a new directory -- updating the latest symlink if needed -- and run the following:
# version are for example only
# create new version
cp -r 0.12.5 0.12.6
# update symlinks
rm latest 0.12
ln -s 0.12.6 latest
ln -s 0.12.6 0.12
# generate new Dockerfile(s)
make generate/0.12.6
# build new images
make build/{0.12.6,0.12,latest}
# test new images
make test/{0.12.6,0.12,latest}
# commit changes
git add -A
git commit -a -m 'Adding version 0.12.6'
If updating either the template or the parent image:
make generate build test
Send me a pull request.
Content type
Image
Digest
sha256:0f75566d9…
Size
126.3 MB
Last updated
almost 11 years ago
docker pull jmervine/nodebox:0.10.36-fat