Documentation ¶
Index ¶
- type Client
- func (c *Client) Create(namespace string, reader io.Reader) error
- func (c *Client) Delete(namespace string, reader io.Reader) error
- func (c *Client) ForwardPort(namespace, podName string, remote int) (*Tunnel, error)
- func (c *Client) Get(namespace string, reader io.Reader) (string, error)
- func (c *Client) Update(namespace string, currentReader, modifiedReader io.Reader) error
- func (c *Client) WatchUntilReady(namespace string, reader io.Reader) error
- type ResourceActorFunc
- type Tunnel
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client represents a client capable of communicating with the Kubernetes API.
func (*Client) Create ¶
Create creates kubernetes resources from an io.reader
Namespace will set the namespace
func (*Client) Delete ¶
Delete deletes kubernetes resources from an io.reader
Namespace will set the namespace
func (*Client) ForwardPort ¶
ForwardPort opens a tunnel to a kubernetes pod
func (*Client) Get ¶
Get gets kubernetes resources as pretty printed string
Namespace will set the namespace
func (*Client) Update ¶
Update reads in the current configuration and a modified configuration from io.reader
and creates resources that don't already exists, updates resources that have been modified and deletes resources from the current configuration that are not present in the modified configuration
Namespace will set the namespaces
func (*Client) WatchUntilReady ¶
WatchUntilReady watches the resource given in the reader, and waits until it is ready.
This function is mainly for hook implementations. It watches for a resource to hit a particular milestone. The milestone depends on the Kind.
For most kinds, it checks to see if the resource is marked as Added or Modified by the Kubernetes event stream. For some kinds, it does more:
- Jobs: A job is marked "Ready" when it has successfully completed. This is ascertained by watching the Status fields in a job's output.
Handling for other kinds will be added as necessary.
type ResourceActorFunc ¶
ResourceActorFunc performs an action on a single resource.