k8s

package
v0.0.136 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 1, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultWatchInterval = 1 * time.Second

Variables

This section is empty.

Functions

func ExecCommand

func ExecCommand(ctx context.Context, cfg *rest.Config, podNamespace, podName, containerName string, cmd []string, opts *ExecOptions) error

Types

type ExecOptions

type ExecOptions struct {
	In              io.Reader
	Out             io.Writer
	ErrOut          io.Writer
	TTY             bool
	InterruptParent *interrupt.Handler
	PortMappings    []string
}

func (*ExecOptions) CreateTTY

type JobRunner added in v0.0.135

type JobRunner struct {
	Namespace         string
	AppName           string
	MainContainerName string
	JobDefinitionName string
	NewConfigFn       k8s.NewConfiger
}

func (JobRunner) Run added in v0.0.135

func (r JobRunner) Run(ctx context.Context, options admin.RunOptions, cmd []string) error

type PortForwarder added in v0.0.136

type PortForwarder struct {
	Transport http.RoundTripper
	Upgrader  spdy.Upgrader
	Request   *rest.Request
}

func NewPortForwarder added in v0.0.136

func NewPortForwarder(cfg *rest.Config, podNamespace, podName string, portMappings []string) (*PortForwarder, error)

func (*PortForwarder) ForwardPorts added in v0.0.136

func (f *PortForwarder) ForwardPorts(stop <-chan struct{}, opts *ExecOptions)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL