Merge pull request #322 from docker/fix_attach_logs

Fix logs replacement when streaming logs on windows
This commit is contained in:
Djordje Lukic 2020-07-02 10:37:27 +02:00 committed by GitHub
commit 8e8c868a70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -18,8 +18,8 @@ package cmd
import (
"context"
"os"
"github.com/containerd/console"
"github.com/pkg/errors"
"github.com/spf13/cobra"
@ -59,7 +59,7 @@ func runLogs(ctx context.Context, containerName string, opts logsOpts) error {
req := containers.LogsRequest{
Follow: opts.Follow,
Tail: opts.Tail,
Writer: os.Stdout,
Writer: console.Current(),
}
return c.ContainerService().Logs(ctx, containerName, req)