Index

The Shipping Container

Paper Large-scale cluster management at Google with Borg

100%Open SVG ↗
Lesson 1 -- The Shipping Container (Docker)THE STORY -- 1956, on the docks:barrels, sacks, odd crates -- alldifferent. loaded by hand. slow, broke.the boxone standard steel box: any crane,any ship, any truck. trade exploded.DOCKER = that same box,but for software (below)THE PROBLEM -- "but it works on my machine!"appDEV laptop: has python3.9, libX, envdeploy ->PROD serverlibX missing -> crash"...but it workson my machine"same app, different surroundings -> it breaks.THE FIX -- seal it into one boxapp + libs + runtime + configIMAGElaptopservercloudeach running box = a CONTAINER --same contents on any host (same CPU family)LAYERS -- why a rebuild is tiny & fastbase OSpython runtimelibrariesYOUR CODEbase OSpython runtimelibrariesYOUR CODE v2container Acontainer Btop slab changed? only THAT onerebuilds -- seconds, not minutes.the lower slabs are identical, so they'rebuilt & downloaded ONCE and shared byboth boxes. that's why images stay small.JARGON, DECODEDimage = sealed box on disk | container = image running | Dockerfile = the recipe to build it | registry (Docker Hub) = the box warehouse (push / pull)You already live this: every shop service (users, core, payments) is a container -- that's why "more stalls when busy" (SD-01) just works.

Lessons that use this board

Lesson 1 -- The Shipping Container (Docker) THE STORY -- 1956, on the docks: barrels, sacks, odd crates -- all different. loaded by hand. slow, broke. the box one standard steel box: any crane, any ship, any truck. trade exploded. DOCKER = that same box, but for software (below) THE PROBLEM -- "but it works on my machine!" app DEV laptop: has python3.9, libX, env deploy -> PROD server libX missing -> crash "...but it works on my machine" same app, different surroundings -> it breaks. THE FIX -- seal it into one box app + libs + runtime + config IMAGE laptop server cloud each running box = a CONTAINER -- same contents on any host (same CPU family) LAYERS -- why a rebuild is tiny & fast base OS python runtime libraries YOUR CODE base OS python runtime libraries YOUR CODE v2 container A container B top slab changed? only THAT one rebuilds -- seconds, not minutes. the lower slabs are identical, so they're built & downloaded ONCE and shared by both boxes. that's why images stay small. JARGON, DECODED image = sealed box on disk | container = image running | Dockerfile = the recipe to build it | registry (Docker Hub) = the box warehouse (push / pull) You already live this: every shop service (users, core, payments) is a container -- that's why "more stalls when busy" (SD-01) just works.

Saved in this browser only.

Running a Container →