Containers are runtime instances of an image and have a lot of associated data that characterizes their behavior. To get more information about a specific container, we can use the inspect command. As usual, we have to provide either the container ID or name to identify the container of which we want to obtain the data. So, let's inspect our sample container:
$ docker container inspect trivia
The response is a big JSON object full of details. It looks similar to this:
[
{
"Id": "48630a3bf188...",
...
"State": {
"Status": "running",
"Running": true,
...
},
"Image": "sha256:bbc92c8f014d605...",
...
"Mounts": [],
"Config": {
"Hostname...