Merge pull request #20647 from coolljt0725/fix_20638
Fix exec start api with detach and AttachStdin at same time. fixes #2… Upstream-commit: cee4ff1c4ac0bb47ed847f3bb725fd6233613937 Component: engine
This commit is contained in:
@@ -157,7 +157,7 @@ func (d *Daemon) ContainerExecStart(name string, stdin io.ReadCloser, stdout io.
|
||||
logrus.Debugf("starting exec command %s in container %s", ec.ID, c.ID)
|
||||
d.LogContainerEvent(c, "exec_start: "+ec.ProcessConfig.Entrypoint+" "+strings.Join(ec.ProcessConfig.Arguments, " "))
|
||||
|
||||
if ec.OpenStdin {
|
||||
if ec.OpenStdin && stdin != nil {
|
||||
r, w := io.Pipe()
|
||||
go func() {
|
||||
defer w.Close()
|
||||
|
||||
Reference in New Issue
Block a user