Step 6 of 8 · lab · 20 min
Container won't start
A status page in a Docker container stopped opening after an edit. Find the cause and fix it.
Situation
The status page of the inventory project runs in the Docker container web from the
inventory-web:1.0 image: the developers built the image, and the page is already inside.
The container serves it on port 8080, and it is created by the script /opt/web/run.sh.
Since yesterday's edit the page does not open.
Run docker commands with sudo: the student user has no direct access to Docker. There is
no internet on the machine, and the image is already loaded.
Task
Make it so that:
- the
webcontainer from theinventory-web:1.0image is running and not restarting; curl http://localhost:8080/gets the status page from thewebcontainer;- after the machine reboots,
webcomes up by itself, as before.
Lab · on your own
No commands are given in this lab: type them in the terminal yourself. Goals are checked on the machine after every command.
Goals
0 of 3-
Container web from the inventory-web:1.0 image is running and not restarting — not done yet
-
Container web serves the status page at http://localhost:8080/ — not done yet
-
Container web will come up by itself after a reboot — not done yet
The machine is starting
Hints
0 of 3Lab goals
0 of 3-
Container web from the inventory-web:1.0 image is running and not restarting — not done yet
-
Container web serves the status page at http://localhost:8080/ — not done yet
-
Container web will come up by itself after a reboot — not done yet
Goals are checked on the machine after every command.