Documentation
¶
Index ¶
- func BuildPVCManifest(namespace, name, size, storageClass string, labels map[string]string, ...) ([]byte, error)
- func BuildPodManifest(namespace, name string, labels map[string]string, ...) ([]byte, error)
- func PreparePodSpec(podSpec corev1.PodSpec, volumes []corev1.Volume, ...) (corev1.PodSpec, error)
- func PreparePodSpecForTarget(podSpec corev1.PodSpec, volumes []corev1.Volume, ...) (corev1.PodSpec, error)
- type Client
- func (c *Client) AnnotatePod(ctx context.Context, namespace, pod, key, value string) error
- func (c *Client) Apply(ctx context.Context, namespace string, manifest []byte) error
- func (c *Client) CopyFromPod(ctx context.Context, namespace, podName, remotePath, localPath string) error
- func (c *Client) CopyToPod(ctx context.Context, namespace, localPath, podName, remotePath string) error
- func (c *Client) CopyToPodInContainer(ctx context.Context, ...) error
- func (c *Client) Delete(ctx context.Context, namespace string, kind string, name string, ...) error
- func (c *Client) DeleteByRef(ctx context.Context, namespace string, apiVersion string, kind string, ...) error
- func (c *Client) DescribePod(ctx context.Context, namespace, pod string) (string, error)
- func (c *Client) ExecInteractive(ctx context.Context, namespace, pod string, tty bool, command []string, ...) error
- func (c *Client) ExecSh(ctx context.Context, namespace, pod string, script string) ([]byte, error)
- func (c *Client) ExecShInContainer(ctx context.Context, namespace, pod, container, script string) ([]byte, error)
- func (c *Client) ExtractTarToPod(ctx context.Context, namespace, podName, remoteDir string, tarStream io.Reader) error
- func (c *Client) GetPodAnnotation(ctx context.Context, namespace, pod, key string) (string, error)
- func (c *Client) GetPodSummary(ctx context.Context, namespace, name string) (*PodSummary, error)
- func (c *Client) ListPods(ctx context.Context, namespace string, allNamespaces bool, ...) ([]PodSummary, error)
- func (c *Client) PersistentVolumeClaimExists(ctx context.Context, namespace, name string) (bool, error)
- func (c *Client) PodContainerNames(ctx context.Context, namespace, pod string) ([]string, error)
- func (c *Client) PortForward(ctx context.Context, namespace, pod string, forwards []string, ...) error
- func (c *Client) ResourceExists(ctx context.Context, namespace string, apiVersion string, kind string, ...) (bool, error)
- func (c *Client) StreamFromPod(ctx context.Context, namespace, podName, script string, stdout io.Writer) error
- func (c *Client) StreamPodLogs(ctx context.Context, namespace, pod string, opts LogStreamOptions, ...) error
- func (c *Client) StreamShInContainer(ctx context.Context, namespace, pod, container, script string, ...) error
- func (c *Client) TouchPodActivity(ctx context.Context, namespace, pod string) error
- func (c *Client) WaitReady(ctx context.Context, namespace, pod string, timeout time.Duration) error
- func (c *Client) WaitReadyWithProgress(ctx context.Context, namespace, pod string, timeout time.Duration, ...) error
- func (c *Client) WatchPodEvents(ctx context.Context, namespace, pod string, ...)
- type LogStreamOptions
- type PodReadinessProgress
- type PodSummary
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildPVCManifest ¶
func BuildPodManifest ¶
func PreparePodSpec ¶
Types ¶
type Client ¶
type Client struct {
Context string
// contains filtered or unexported fields
}
func (*Client) AnnotatePod ¶ added in v0.2.0
func (*Client) CopyFromPod ¶
func (*Client) CopyToPodInContainer ¶ added in v0.3.0
func (*Client) DeleteByRef ¶ added in v0.3.0
func (*Client) DescribePod ¶
func (*Client) ExecInteractive ¶
func (*Client) ExecShInContainer ¶
func (*Client) ExtractTarToPod ¶
func (*Client) GetPodAnnotation ¶ added in v0.2.0
func (*Client) GetPodSummary ¶
func (*Client) PersistentVolumeClaimExists ¶ added in v0.2.6
func (*Client) PodContainerNames ¶ added in v0.3.0
func (*Client) PortForward ¶
func (*Client) ResourceExists ¶ added in v0.3.0
func (*Client) StreamFromPod ¶
func (*Client) StreamPodLogs ¶ added in v0.3.0
func (*Client) StreamShInContainer ¶ added in v0.2.11
func (*Client) TouchPodActivity ¶
func (*Client) WaitReadyWithProgress ¶
func (*Client) WatchPodEvents ¶ added in v0.3.1
func (c *Client) WatchPodEvents(ctx context.Context, namespace, pod string, onEvent func(reason, message string))
WatchPodEvents watches Kubernetes events for the given pod and calls onEvent for each relevant event. It blocks until the context is cancelled. Only events with reasons in the allowlist are forwarded.
type LogStreamOptions ¶ added in v0.3.0
type PodReadinessProgress ¶
Click to show internal directories.
Click to hide internal directories.