Skip to content

Commit

Permalink
Improve command run verbose output
Browse files Browse the repository at this point in the history
Show command as it would look like in a terminal.
  • Loading branch information
HeavyWombat committed May 14, 2024
1 parent 47891d2 commit 38506de
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/havener/kubexec.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import (
"context"
"fmt"
"io"
"strings"
"time"

corev1 "k8s.io/api/core/v1"
Expand All @@ -40,7 +41,7 @@ import (

// PodExec executes the provided command in the referenced pod's container.
func (h *Hvnr) PodExec(pod *corev1.Pod, container string, command []string, stdin io.Reader, stdout io.Writer, stderr io.Writer, tty bool) error {
logf(Verbose, "Executing command on pod: %#v", command)
logf(Verbose, "Executing command on pod: `%v`", strings.Join(command, " "))

req := h.client.CoreV1().RESTClient().Post().
Resource("pods").
Expand Down

0 comments on commit 38506de

Please sign in to comment.