mirror of
https://github.com/docker/docs.git
synced 2026-04-05 02:38:52 +07:00
Change the behaviour of CmdRun in tty mode: dont kill the process uppon detach
This commit is contained in:
@@ -250,10 +250,7 @@ func (container *Container) Attach(stdin io.ReadCloser, stdinCloser io.Closer, s
|
||||
if cStderr != nil {
|
||||
defer cStderr.Close()
|
||||
}
|
||||
if container.Config.StdinOnce {
|
||||
if container.Config.Tty {
|
||||
defer container.Kill()
|
||||
}
|
||||
if container.Config.StdinOnce && !container.Config.Tty {
|
||||
defer cStdin.Close()
|
||||
}
|
||||
_, err := io.Copy(cStdin, stdin)
|
||||
|
||||
Reference in New Issue
Block a user