Skip to content
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:docker should have a grace way to quit the docker stats container_id #12393

Open
cc272309126 opened this issue Apr 15, 2015 · 12 comments
Labels
area/runtime kind/enhancement Enhancements are not bugs or new features but can improve usability or performance.

Comments

@cc272309126
Copy link
Contributor

I think there should be a grace way to quit the docker stats container_id like below

  1. docker run -d image_id
  2. docker stats container_id
  3. press the key 'q' or other key it will exit the docker stats routine. Now it use ctrl+c to exit it.
@phemmer
Copy link
Contributor

phemmer commented Apr 15, 2015

What is wrong with ctrl+cl? ctrl+c is a standard way of quitting console based applications.

@thaJeztah thaJeztah added UX kind/enhancement Enhancements are not bugs or new features but can improve usability or performance. labels Apr 15, 2015
@thaJeztah
Copy link
Member

I think ctrl-c is fine, but it could be convenient if q was added; docker stats "feels" a bit like top and out of habit users may try q to exit stats.

@crosbymichael thoughts?

@phemmer
Copy link
Contributor

phemmer commented Apr 15, 2015

The only thing I think that might complicate this is that for q to work, the tty has to be in character-input mode. This is easy enough to do on unix, but it's not cross platform. And with windows being supported, I dunno how hard this is to do over there.

@thaJeztah
Copy link
Member

I dunno how hard this is to do over there.

Well, anything on Windows is hard 😄

At this point I'm just checking if there's any "support" for adding this from the maintainers side. I don't regard this a priority issue in any case, but if there's no backing from the maintainers, there's no reason to keep it open.

We'll see :)

@thaJeztah
Copy link
Member

Some additional information / suggestions can be found in #12464

@ahmetb
Copy link
Contributor

ahmetb commented Apr 17, 2015

@phemmer it might not be as hard as you expected. :) We developed some cool ANSI emulation (docker run -it ubuntu bash works inside cmd.exe) and we'll be improving that. I can't see why this can't be done. :)

@jessfraz jessfraz added kind/feature Functionality or other elements that the project doesn't currently have. Features are new and shiny and removed kind/feature Functionality or other elements that the project doesn't currently have. Features are new and shiny UX labels Sep 8, 2015
@dwo
Copy link

dwo commented Feb 12, 2016

For what it's worth, I expected q to be the way to quit when I saw docker stats for the first time.

Even if ctrl-c remains only way to do this, I think it'd be nice to make it obvious (eg. Press ctrl-c to exit somewhere while it is running).

@icecrime icecrime added area/runtime and removed kind/feature Functionality or other elements that the project doesn't currently have. Features are new and shiny labels Sep 10, 2016
@smunsonNamely
Copy link

CTL-C also kills the DOS window. This is not cool.

@thaJeztah
Copy link
Member

@smunsonNamely could you provide more details on that? CTRL-C should not kill the shell itself (and we tried, but are not able to reproduce that situation)

@Mugane
Copy link

Mugane commented Sep 29, 2021

Ctrl+c does nothing. Q does nothing... Ctrl+z does nothing! Esc does nothing!! How do I close this thing?! MinGQ64/Docker Quickstart on Windows.

@JannemanDev
Copy link

JannemanDev commented Sep 11, 2022

We use this stats command from a shell script and want to return to our menu. Now crtl-c quits our whole script and users cant return to our menu. A simple q would be nice.

@dlt-green
Copy link

dlt-green commented Sep 16, 2022

We use this stats command from a shell script and want to return to our menu. Now crtl-c quits our whole script and users cant return to our menu. A simple q would be nice.

we have the same problem, we wanted to close the live stream maybe with any key or Q, crtl-c is there a very uncool solution, because this breaks also shell skripts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/runtime kind/enhancement Enhancements are not bugs or new features but can improve usability or performance.
Projects
None yet
Development

No branches or pull requests