docker logs
docker logs [-f] [--tail n] <container>
Risk: Safe
What it does
Shows what a container printed.
When to use it
First thing to check when a container misbehaves.
Example
$ docker logs webRead web's messages.
$ docker logs -f webKeep watching new lines. Ctrl+C stops.
$ docker logs --tail 5 webOnly the last 5 lines.
Learn it in: Follow the logs · Official docs