Skip to content
Theory · Data: volumes and bind mounts · lesson 1 of 7

Where a container's changes live

Room db is being swept clean, while the safe-deposit box db-data at reception stays untouched

Picture a hotel room. While you stay in it, you can move the armchair, unpack your things and leave a note on the desk. After you check out, the room is cleaned, and the next guest finds it as it was before you. That is why valuables go not into the room but into the safe-deposit box at reception: the box is not cleaned along with the room.

In this lesson

  • The writable layer is the room
  • A stop keeps the layer
  • A removal wipes everything
  • Why data is not kept in the layer
  • A volume is the safe-deposit box
  • Where the picture stops working
  • Common mistake
  • Key points