-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
[BUG] docker compose up not returning shell and erroneously detecting error #10661
Comments
I also started experiencing this issue after the latest update |
I wonder this is the same as #10648 |
Thanks @ndeloof, looks like the same issue alright. Had a look at through #10648 and #10634. The work-arounds are good for now. Unfortunately, it means that builds are failing regularly. Other colleagues seeing this issue. Will update if I find a fix or it goes away for good. |
Kill executed on the second Ctrl-C of docker compose up was filtering containers depending on its state. In some cases the containers can reach an state for what these filters don't get any container, and the command keeps reporting `no container to kill`. Remove this filtering, so it tries to kill any container it finds, independently of its state. Fixes docker#10661 Signed-off-by: Jaime Soriano Pastor <jaime.soriano@elastic.co>
I found a similar issue, that I could reproduce by hitting Ctrl-C quickly a couple of times on a container that is capturing signals and doesn't die with compose stop. I think the problem is that kill only tries to kill running containers, but in these cases the pending containers seem to have other states. I have opened a PR to make this kill attempt to kill any container, independently of their state: #11718 It'd be great if anyone else having this issue could give a try to my fix. |
Kill executed on the second Ctrl-C of docker compose up was filtering containers depending on its state. In some cases the containers can reach an state for what these filters don't get any container, and the command keeps reporting `no container to kill`. Remove this filtering, so it tries to kill any container it finds, independently of its state. Fixes #10661 Signed-off-by: Jaime Soriano Pastor <jaime.soriano@elastic.co>
Description
I want to get this issue down now before I forget some details, so apologies if it's a little light on detail. I will update as I reproduce this error for myself.
I'm running a fairly large project with docker compose and am running an issue where
docker compose up -d
anddocker compose up
are not returning the shell properly.In the case of detached, one of the services is showing an error when I bring it up. When this happenss, the shell is not returned, even with a
CTRL+C
. The only way to exit is the kill the service directly w/kill -HUP <PID>
. When I get the shell back, I can attach to the logs and can confirm that the service that showed error has no errors (although this happens if service genuinely errors or now).In the non-detached case, the services all come up without error and I attach to the output.log correctly. However, if I do a
CTRL-C
here, the services are stopped but I do not get my shell back automatically. I must then repeatedly doCTRL-C
which results inI tried this in in zsh and bash shells, and each of these in xterm and gnome-terminal (xterm-256color).
Three things that might be causing it/ that are different from similar compose files:
Steps To Reproduce
docker compose up -d
(see psuedo-compose below)**** I will add to this as I try reproduce with simpler compose files
Compose Version
Docker Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: