v1

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: May 16, 2022 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CoreV1Client

type CoreV1Client struct {
	// contains filtered or unexported fields
}

CoreV1Client is used to interact with features provided by the group.

func New

func New(c rest.Interface) *CoreV1Client

New creates a new CoreV1Client for the given RESTClient.

func NewForConfig

func NewForConfig(c *rest.Config) (*CoreV1Client, error)

NewForConfig creates a new CoreV1Client for the given config.

func NewForConfigOrDie

func NewForConfigOrDie(c *rest.Config) *CoreV1Client

NewForConfigOrDie creates a new CoreV1Client for the given config and panics if there is an error in the config.

func (*CoreV1Client) Pods

func (c *CoreV1Client) Pods(namespace string) PodInterface

func (*CoreV1Client) RESTClient

func (c *CoreV1Client) RESTClient() rest.Interface

RESTClient returns a RESTClient that is used to communicate with API server by this client implementation.

type CoreV1Interface

type CoreV1Interface interface {
	RESTClient() rest.Interface
	PodsGetter
}

type PodExpansion

type PodExpansion interface {
	Bind(ctx context.Context, binding *v1.Binding, opts metav1.CreateOptions) error
	Evict(ctx context.Context, eviction *policy.Eviction) error
	GetLogs(name string, opts *v1.PodLogOptions) *restclient.Request
	ProxyGet(scheme, name, port, path string, params map[string]string) restclient.ResponseWrapper
}

The PodExpansion interface allows manually adding extra methods to the PodInterface.

type PodInterface

type PodInterface interface {
	Create(ctx context.Context, pod *v1.Pod, opts metav1.CreateOptions) (*v1.Pod, error)
	Update(ctx context.Context, pod *v1.Pod, opts metav1.UpdateOptions) (*v1.Pod, error)
	UpdateStatus(ctx context.Context, pod *v1.Pod, opts metav1.UpdateOptions) (*v1.Pod, error)
	Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
	DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
	Get(ctx context.Context, name string, opts metav1.GetOptions) (*v1.Pod, error)
	List(ctx context.Context, pod *v1.Pod, opts metav1.ListOptions) (*v1.PodList, error)
	Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error)
	Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.Pod, err error)
	Apply(ctx context.Context, pod *corev1.PodApplyConfiguration, opts metav1.ApplyOptions) (result *v1.Pod, err error)
	ApplyStatus(ctx context.Context, pod *corev1.PodApplyConfiguration, opts metav1.ApplyOptions) (result *v1.Pod, err error)
	GetEphemeralContainers(ctx context.Context, podName string, options metav1.GetOptions) (*v1.EphemeralContainers, error)
	UpdateEphemeralContainers(ctx context.Context, podName string, ephemeralContainers *v1.EphemeralContainers, opts metav1.UpdateOptions) (*v1.EphemeralContainers, error)

	PodExpansion
}

PodInterface has methods to work with Pod resources.

type PodsGetter

type PodsGetter interface {
	Pods(namespace string) PodInterface
}

PodsGetter has a method to return a PodInterface. A group's client should implement this interface.

Jump to

Keyboard shortcuts

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