Skip to content
This repository was archived by the owner on Jan 13, 2023. It is now read-only.

Commit fab0a90

Browse files
authored
Merge pull request #49 from redskyops/fix/filter-output
Silence stderr on the forked exec
2 parents 7c1a611 + 62421f3 commit fab0a90

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

redskyctl/internal/commands/initialize/generator.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,12 +85,13 @@ func (o *GeneratorOptions) generate(ctx context.Context) error {
8585
args = append(args, "--", "install")
8686

8787
// Run the command straight through to the configured output stream
88-
// TODO How do we filter out the warning about not being able to attach?
8988
kubectlRun, err := o.Config.Kubectl(ctx, args...)
9089
if err != nil {
9190
return err
9291
}
92+
// TODO Should we buffer this and verify we got valid YAML?
9393
kubectlRun.Stdout = o.Out
94-
kubectlRun.Stderr = o.ErrOut
94+
// TODO What is the best way to filter out the "Error attaching, ..." line from the writer?
95+
// kubectlRun.Stderr = o.ErrOut
9596
return kubectlRun.Run()
9697
}

0 commit comments

Comments
 (0)