- All Courses
- Docker Essentials
- Containers in a Pipeline
- Debugging a failing container
Debugging a failing container
The exit code narrows the problem immediately: a non-zero application code points at your code, while codes from a signal usually mean the container was killed — most often an…
Overview
Start with the exit code
The exit code narrows the problem immediately: a non-zero application code points at your code, while codes from a signal usually mean the container was killed — most often an out-of-memory kill, which produces no application error at all.
Inspecting a container shows the resolved configuration: the actual command, environment, mounts, and network. It is frequently different from what you thought you specified.
When a container exits instantly, override the entrypoint with a shell and run the command by hand. The failure is usually a missing file or a permission the runtime image does not have.
In this lesson you will:
- Read logs and exit codes
- Inspect a container that will not start
- Reproduce a failure interactively
Resources
Notes are not saved yet — they clear when you leave this page.
Building images in CI
1h