diff --git a/pkg/cmd/diag/logs.go b/pkg/cmd/diag/logs.go index 9b09a4a..12f4d9f 100644 --- a/pkg/cmd/diag/logs.go +++ b/pkg/cmd/diag/logs.go @@ -163,7 +163,7 @@ func (o *LogsOptions) Run() error { LogDrainTime: o.drainTime, } - if colorNotAvailable() || o.noColor { + if colorNotAvailable(o.IOStreams.Out) || o.noColor { color.NoColor = true } return printer.PrintLogs(o.ctx, o.clientset.CoreV1().Pods(o.resultingContext.Namespace), o.podAndContainerNames)