diff options
author | Matthew Heon <matthew.heon@gmail.com> | 2018-04-11 14:44:11 -0400 |
---|---|---|
committer | Atomic Bot <atomic-devel@projectatomic.io> | 2018-04-13 18:43:44 +0000 |
commit | 6609d555f75568bb4f1394736a3e3b31e5f0d355 (patch) | |
tree | 92cfca059a58882d205acd2c575b587850ae1798 /cmd/podman/run.go | |
parent | 5e03cec7ec83f8ff8b31a89a6180dda203b04d9c (diff) | |
download | podman-6609d555f75568bb4f1394736a3e3b31e5f0d355.tar.gz podman-6609d555f75568bb4f1394736a3e3b31e5f0d355.tar.bz2 podman-6609d555f75568bb4f1394736a3e3b31e5f0d355.zip |
Fix terminal attach
Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
Closes: #608
Approved by: baude
Diffstat (limited to 'cmd/podman/run.go')
-rw-r--r-- | cmd/podman/run.go | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/cmd/podman/run.go b/cmd/podman/run.go index b8d6e0968..cafb16d9d 100644 --- a/cmd/podman/run.go +++ b/cmd/podman/run.go @@ -179,8 +179,7 @@ func runCmd(c *cli.Context) error { } } - attachChan, err := startAttachCtr(ctr, outputStream, errorStream, inputStream, c.String("detach-keys")) - if err != nil { + if err := startAttachCtr(ctr, outputStream, errorStream, inputStream, c.String("detach-keys"), c.BoolT("sig-proxy")); err != nil { // This means the command did not exist exitCode = 127 if strings.Index(err.Error(), "permission denied") > -1 { @@ -189,16 +188,6 @@ func runCmd(c *cli.Context) error { return err } - if c.BoolT("sig-proxy") { - ProxySignals(ctr) - } - - // Wait for attach to complete - err = <-attachChan - if err != nil { - return errors.Wrapf(err, "error attaching to container %s", ctr.ID()) - } - if ecode, err := ctr.ExitCode(); err != nil { logrus.Errorf("unable to get exit code of container %s: %q", ctr.ID(), err) } else { |