Learn how to build a simple Node.js web server with Docker. In this lesson, we'll create a Dockerfile for a simple Node.js script, copy and build it into a Docker image, and start a container to run the web server.
Very useful tutorial. I had trouble gracefully stopping the container (CTRL+C doesn't work).
In that situation this might help: https://forums.docker.com/t/docker-run-cannot-be-killed-with-ctrl-c/13108
Very useful tutorial. I had trouble gracefully stopping the container (CTRL+C doesn't work).
Thanks for the tip; I had the same problem. The suggested solution of opening another terminal and running docker stop <id>
worked for me.
The image doesn't build unfortunately. Something about index.js not being in the context.