Help us shape the future of Go! Take the 2026 Go Developer Survey

kubernetes

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2022 License: Apache-2.0 Imports: 14 Imported by: 4

Documentation

Index

Constants

View Source
const (

	// KubernetesHostNameLabel is the kubernetes hostname label
	KubernetesHostNameLabel = kubernetesLabelPrefix + blockdevice.HostName

	// BlockDeviceTagLabel is the label used to tag a blockdevice for
	// a particular use case.
	// BlockDevices having this label can only be claimed by BDCs which
	// have a matching label selector.
	BlockDeviceTagLabel = openebsLabelPrefix + blockDeviceTag
)
View Source
const (
	// NamespaceENV is the name of environment variable to get the namespace
	NamespaceENV = "NAMESPACE"
)

Variables

This section is empty.

Functions

func GenerateLabelFilter added in v0.5.0

func GenerateLabelFilter(key, value string) (interface{}, error)

GenerateLabelFilter is used to generate a label filter that can be used while listing resources

func GenerateLabelFilterWithOp added in v0.8.0

func GenerateLabelFilterWithOp(key, op, value string) (interface{}, error)

GenerateLabelFilterWithOp creates a label filter with the given operator between key and value

Types

type Client

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

Client is the wrapper over the k8s client that will be used by NDM to interface with etcd

func New

func New() (Client, error)

New creates a new client object using the default config

func (*Client) InitClient added in v0.5.0

func (cl *Client) InitClient() error

InitClient sets the client using the config

func (*Client) ListBlockDevice

func (cl *Client) ListBlockDevice(filters ...interface{}) ([]blockdevice.BlockDevice, error)

ListBlockDevice lists the block device from etcd based on the filters used

func (*Client) RegisterAPI

func (cl *Client) RegisterAPI() error

RegisterAPI registers the API scheme in the client using the manager. This function needs to be called only once a client object

func (*Client) SetClient added in v0.5.0

func (cl *Client) SetClient(client2 client.Client)

SetClient sets the given client

Jump to

Keyboard shortcuts

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