-
Notifications
You must be signed in to change notification settings - Fork 18.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposal: Enhance docker info output with running and exited/stopped containers #15639
Comments
I wonder if we're going to need a I can see the use case here, just wondering if we're not overloading this endpoint with too much information |
Adding a flag for this output to be optional seems like a good idea as long as this information is also available with the remote API through a query parameter. It is just to offer an accurate overview of the machine/cluster to the end user. Especially in Swarm where we manage tens/hundreds of machines and where |
Yes, I understand. Bit of brainstorming here; is Swarm interested in a "snapshot" of this information, or a stream? i.e. could a global "metrics" endpoint be useful, not only including number of containers, but also system load/memory usage? |
If we're only talking about a small number of properties I'm not sure its worth introducing a |
But +1 to adding the new fields |
@duglin true, we can handle a few more lines, but since there's also the PR to expand the Operating System node to add more information, at some point this may become an unwieldy list. Doesn't have to be introduced with this proposal, but we may want to start thinking about this. |
Yup, I'm just not a fan of us deciding for people what's important. Especially when its due to a random time-based thing - like "new stuff is hidden" and "existing stuff is important/shown", when its possible the existing stuff could be less important than the new stuff. E.g. The "ID" is pretty useless (I think) to most people, but (as a proof point) that's just my opinion. |
Yes, splitting up in "default" and "verbose" could be a challenge. Hence I was wondering if we need a "metrics" endpoint #15639 (comment) to have the "info" endpoint return "static" information (version, daemon config, platform), and the metrics endpoint return "live" / "runtime" information. |
@thaJeztah Just wondering if this is worth splitting this in two separate endpoints considering the amount of information that a I like the idea of a |
Instead of arbitrarily picking what we think users want for a verbose flag, could we follow the pattern of inspect with --format=... to allow CLI consumers to select which subset they want to see? In fact, I'd love to see this or some similar pattern make its way into the API so apps can also subset response payloads to only the data they care about. |
Why not just add those fields to |
#dibs |
Solved in #19249. |
Currently the output of
docker info
looks like:This does not really help at a first glance to assess how many containers are running on a machine. Indeed on those 1362 containers, I only have 10 running containers, the rest are stopped. I might have a few paused containers too.
This would be useful in
docker info
to show more informations on the current state of containers:This also means adding this to the remote API on
/info
. This way we can also use it in Swarm as a quick way to assess the load on machines (see related issue on the Swarm side docker-archive/classicswarm#1140)I agree that this information is provided somehow by
docker ps
but this could be an added convenience to have this oninfo
😃The text was updated successfully, but these errors were encountered: