Documentation
¶
Index ¶
- Variables
- func Run(ctx context.Context, client ExecClient, namespace, pod string, ...) error
- func RunOnContainer(ctx context.Context, client ExecClient, namespace, pod, container string, ...) error
- func RunWithRetry(ctx context.Context, client ExecClient, namespace, pod string, ...) error
- type ExecClient
- type ExecContainerClient
- type RetryPolicy
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultRetryPolicy = RetryPolicy{ MaxAttempts: 3, InitialBackoff: 1 * time.Second, MaxBackoff: 5 * time.Second, }
Functions ¶
func RunOnContainer ¶ added in v0.7.0
func RunOnContainer(ctx context.Context, client ExecClient, namespace, pod, container string, command []string, tty bool, stdin io.Reader, stdout io.Writer, stderr io.Writer) error
RunOnContainer executes a command in a specific container within a pod. If container is empty, it falls back to the default ExecInteractive behavior.
Types ¶
type ExecClient ¶
type ExecContainerClient ¶ added in v0.7.0
type ExecContainerClient interface {
ExecClient
ExecInteractiveInContainer(ctx context.Context, namespace, pod, container string, tty bool, command []string, stdin io.Reader, stdout io.Writer, stderr io.Writer) error
}
ExecContainerClient extends ExecClient with container-targeted exec.
Click to show internal directories.
Click to hide internal directories.