Docker Image for node apps with alpine linux and native dependencies
Supported tags and respective Dockerfile links
- 7.10.0, 7.10, 7, latest (7.10/Dockerfile)
- 7.10.0-onbuild, 7.10-onbuild, 7-onbuild, onbuild (7.10/onbuild/Dockerfile)
- 6.10.3, 6.10, 6 (6.10/Dockerfile)
- 6.10.3-onbuild, 6.10-onbuild, 6-onbuild (6.10/onbuild/Dockerfile)
- 4.8.3, 4.8, 4 (4.8/Dockerfile)
- 4.8.3-onbuild, 4.8-onbuild, 4-onbuild (4.8/onbuild/Dockerfile)
FROM escaleno/node-krb5:7-onbuild
# replace this with your application's default port
EXPOSE 3000
You can then build and run the Docker image:
docker build -t my-nodejs-app .
docker run -it --rm --name my-running-app my-nodejs-app
The image assumes that your application has a file named package.json listing its dependencies and defining its start script.