Просмотр исходного кода

Don't SetRawTerminal() when exec is run with -T

Signed-off-by: Yuri Kanivetsky <[email protected]>
Yuri Kanivetsky 3 лет назад
Родитель
Сommit
37f763f009
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      pkg/compose/exec.go

+ 1 - 1
pkg/compose/exec.go

@@ -96,7 +96,7 @@ func (s *composeService) interactiveExec(ctx context.Context, opts api.RunOption
 	}
 
 	in := streams.NewIn(opts.Stdin)
-	if in.IsTerminal() {
+	if in.IsTerminal() && opts.Tty {
 		state, err := term.SetRawTerminal(in.FD())
 		if err != nil {
 			return err