Make sure the process start in his own session and grabs the terminal

Upstream-commit: 33a5fe3bd4cb0bd31b01da89c8c4c3321701e7a1
Component: engine
This commit is contained in:
Guillaume J. Charmes
2013-04-05 17:40:55 -07:00
parent 0d916a930b
commit 8f7ae9e955
+1 -1
View File
@@ -202,7 +202,7 @@ func (container *Container) startPty() error {
container.cmd.Stdin = stdoutSlave
// FIXME: The following appears to be broken.
// "cannot set terminal process group (-1): Inappropriate ioctl for device"
// container.cmd.SysProcAttr = &syscall.SysProcAttr{Setctty: true, Setsid: true}
container.cmd.SysProcAttr = &syscall.SysProcAttr{Setctty: true, Setsid: true}
go func() {
defer container.stdin.Close()
Debugf("[startPty] Begin of stdin pipe")