Containers: Docker and compose / Stage 5 of 11 · step 6 of 7
Data after re-creation
Not running
Starting
Situation
The on-call shift keeps its notes in the notes application. It runs in a Docker container of the
same name and lists the notes since the start of the month on port 8080. Last night a colleague
updated the application to version 1.1: they removed the container and created a new one from the
notes:1.1 image with the same port, NOTES_TITLE variable and restart policy. The container is
running, but this morning curl http://localhost:8080/ shows notes: 0.
Run docker commands with sudo: the student user has no direct access to Docker. The machine has
no internet access; the notes:1.0 and notes:1.1 images are already built.
Task
http://localhost:8080/answers with version 1.1 of the application and shows all the notes that existed before the update.- The
notescontainer keeps the notes where they were before the update and has no extra volumes. - The earlier notes are unchanged.
notesruns with the same port,NOTES_TITLEand restart policy as before: it will come up by itself after the machine reboots.
Lab goals
0 of 4-
http://localhost:8080/ answers with notes 1.1 and shows all the notes that existed before the update — not checked yet
-
The notes container keeps the notes where they were before the update and has no extra volumes — not checked yet
-
The earlier notes are unchanged — their checksums match — not checked yet
-
notes runs with the same port, NOTES_TITLE and restart policy as before — it will come up by itself after a reboot — not checked yet
Hints
0 of 3 open · they open one at a time
Hint 1
Show the solution
after 3 failed checks