Containers in Production
The lifecycle from source to running process, layers and caching, what image size actually costs, and the process and signal model that decides whether deploys drop requests.
The full path from a build context to a process serving traffic, and back to a stopped container — with the failure that belongs to each hop.
Why one changed line rebuilds everything below it, why a deleted file is still in the image, and how instruction order decides both.
Size is paid on cold pulls and nowhere else — and an image with no shell is a real operational cost that nobody puts on the other side of the ledger.
Compile in one image, ship another — so the toolchain, the source and the build credentials never reach production.
An image is an immutable package; a container is a running instance of it with a throwaway writable layer — which is why nothing you change inside one survives.
The entrypoint becomes PID 1, PID 1 does not get default signal handling, and a shell wrapper in between is why your container ignores SIGTERM.
Signal, stop accepting work, drain what is in flight, release resources, exit — inside a hard timeout you do not control.
What survives a container's death, what does not, and the order to ask questions in when there is no shell and the evidence is being deleted on every restart.