Project Solution: Running the App

View the project running in development and production mode.

Launch in development mode

Launch the quiz in development mode with auto-building, source maps, and application restarts using the docker-compose.yml configuration in the ./usercode project root:

cd quiz
docker-compose up

The application is accessible via NGINX at http://{nginx_container_IP}:80.

Additionally, you can access:

  • The Node.js application directly at port http://{nodejs_container_IP}:8000.
  • The Node.js debugger at port {nodejs_container_IP}:9229.

You can find the container’s IP using:

docker inspect -f '{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}' nginx


docker inspect -f '{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}' nodejs

📌 The quiz database can be accessed using a MongoDB clientmongodbClient by connecting to http://{mongodb_container_IP}:27017/ with the user ID quizuser and password quizpass.

Click on the “Run” button and the Chrome browser will be opened. You can open output for any of the containers by following the steps mentioned above.

Get hands-on with 1400+ tech skills courses.