resource

package
v0.0.0-...-bb7034b Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	// Reify returns the raw request body given the supplied template values.
	Reify(templateValues interface{}) ([]byte, error)
	// Create creates a new object using the supplied data object for
	// template expansion.
	Create(namespace string, templateValues interface{}) error
	// Delete deletes the object.
	Delete(namespace string, name string) error
	// Update updates the object.
	Update(namespace string, name string, templateValues interface{}) error
	// Patch updates the object using JSON patch.
	Patch(namespace string, name string, data []byte) error
	// Get retrieves the object.
	Get(namespace, name string) (runtime.Object, error)
	// List lists objects based on group, version and kind.
	List(namespace string, labels map[string]string) ([]metav1.Object, error)
	// IsFailed returns true if this resource is in a broken state.
	IsFailed(namespace string, name string) bool
	// Plural returns the plural form of the resource.
	IsEphemeral() bool
	// Plural returns the plural form of the resource.
	Plural() string
	// GetStatusState returns the current status of the resource.
	GetStatusState(runtime.Object) states.State
}

Client manipulates Kubernetes API resources backed by template files.

func NewConfigMapClient

func NewConfigMapClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

configMapClient returns a new pod client.

func NewDeploymentClient

func NewDeploymentClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

NewDeploymentClient returns a new generic resource client.

func NewHPAClient

func NewHPAClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

NewHPAClient returns a new horizontal pod autoscaler client.

func NewIngressClient

func NewIngressClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

NewIngressClient returns a new ingress client.

func NewJobClient

func NewJobClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

NewJobClient returns a new generic resource client.

func NewPodClient

func NewPodClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

NewPodClient returns a new pod client.

func NewServiceClient

func NewServiceClient(globalTemplateValues GlobalTemplateValues, clientSet *kubernetes.Clientset, templateFileName string) Client

NewServiceClient returns a new service client.

type GlobalTemplateValues

type GlobalTemplateValues map[string]string

GlobalTemplateValues encodes values which will be available to all template specializations.

Directories

Path Synopsis
+k8s:deepcopy-gen=package
+k8s:deepcopy-gen=package

Jump to

Keyboard shortcuts

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