actions

package
v0.0.0-...-a0b04c9 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2023 License: LGPL-2.1 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigMap

type ConfigMap struct {
	CurrentNamespace string
	// contains filtered or unexported fields
}

ConfigMap struct for configmap actions

func NewConfigMapAction

func NewConfigMapAction(client corev1.CoreV1Interface) *ConfigMap

NewConfigMapAction get an configmap actions

func (*ConfigMap) Create

func (cm *ConfigMap) Create(configMap *apiv1.ConfigMap) error

Create Create an ConfigMap

func (*ConfigMap) Delete

func (cm *ConfigMap) Delete(cmName string) error

Delete Delete a pod in the client

func (*ConfigMap) Get

func (cm *ConfigMap) Get(cmName string) (*apiv1.ConfigMap, error)

Get get configmap

func (*ConfigMap) List

func (cm *ConfigMap) List() (*apiv1.ConfigMapList, error)

List List all pods in a namespace

func (*ConfigMap) Namespace

func (cm *ConfigMap) Namespace(namespace string) *ConfigMap

Namespace set namespace

func (*ConfigMap) Update

func (cm *ConfigMap) Update(configMap *apiv1.ConfigMap) error

Update Update a pods in the client

type CoreV1

type CoreV1 struct {
	Namespace      *Namespace
	ServiceAccount *ServiceAccount
	ConfigMap      *ConfigMap
	Secret         *Secret
	Pod            *Pod
	Service        *Service
}

CoreV1 struct for access to batchv1 api

func NewCoreV1

func NewCoreV1(client coreInterface.CoreV1Interface) *CoreV1

NewCoreV1 return a batch v1 api

type Namespace

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

Namespace struct for namespace action

func NewNamespaceAction

func NewNamespaceAction(client corev1.NamespaceInterface) *Namespace

NewNamespaceAction return a namespace action

func (*Namespace) Create

func (n *Namespace) Create(namespace *apiv1.Namespace) error

Create Create a namespace in the client

func (*Namespace) Delete

func (n *Namespace) Delete(namespaceName string) error

Delete Delete the namespace in the client

func (*Namespace) Get

func (n *Namespace) Get(namespaceName string) (*apiv1.Namespace, error)

Get Get a namespace in the client

func (*Namespace) List

func (n *Namespace) List() (*apiv1.NamespaceList, error)

List List the namespaces of a client

func (*Namespace) Update

func (n *Namespace) Update(namespace *apiv1.Namespace) error

Update Update a namespace in the client

type Pod

type Pod struct {
	CurrentNamespace string
	// contains filtered or unexported fields
}

Pod struct for actions pod

func NewPodAction

func NewPodAction(client coreInterface.CoreV1Interface) *Pod

NewPodAction return an actions pod

func (*Pod) Create

func (p *Pod) Create(pod *apiv1.Pod) error

Create Create a pods in the client

func (*Pod) Delete

func (p *Pod) Delete(podName string) error

Delete Delete a pod in the client

func (*Pod) Get

func (p *Pod) Get(podName string) (*apiv1.Pod, error)

Get Get a pod from the client

func (*Pod) List

func (p *Pod) List() (*apiv1.PodList, error)

List List all pods in a namespace

func (*Pod) Namespace

func (p *Pod) Namespace(namespace string) *Pod

Namespace set namespace

func (*Pod) Update

func (p *Pod) Update(pod *apiv1.Pod) error

Update Update a pods in the client

type Secret

type Secret struct {
	CurrentNamespace string
	// contains filtered or unexported fields
}

Secret struct for action secret

func NewSecretAction

func NewSecretAction(client coreInterface.CoreV1Interface) *Secret

NewSecretAction get an actions secret

func (*Secret) Create

func (s *Secret) Create(secret *apiv1.Secret) error

Create Create a secrets in the client

func (*Secret) Delete

func (s *Secret) Delete(secretName string) error

Delete Delete a secret in the client

func (*Secret) Get

func (s *Secret) Get(secretName string) (*apiv1.Secret, error)

Get Get a secret from the client

func (*Secret) List

func (s *Secret) List() (*apiv1.SecretList, error)

List List all secrets in a namespace

func (*Secret) Namespace

func (s *Secret) Namespace(namespace string) *Secret

Namespace set namespace

func (*Secret) Update

func (s *Secret) Update(secret *apiv1.Secret) error

Update Update a secrets in the client

type Service

type Service struct {
	CurrentNamespace string
	// contains filtered or unexported fields
}

Service is the struct for access to the service actions

func NewServiceAction

func NewServiceAction(client corev1.CoreV1Interface) *Service

NewServiceAction return a service action

func (*Service) Create

func (s *Service) Create(service *apiv1.Service) error

Create create a service in the client

func (*Service) Delete

func (s *Service) Delete(serviceName string) error

Delete Delete a service in the client

func (*Service) Get

func (s *Service) Get(serviceName string) (*apiv1.Service, error)

Get Get a service in the client

func (*Service) List

func (s *Service) List() (*apiv1.ServiceList, error)

List all services in a namespace

func (*Service) Namespace

func (s *Service) Namespace(namespace string) *Service

Namespace set namespace

func (*Service) Update

func (s *Service) Update(service *apiv1.Service) error

Update a service in the client

type ServiceAccount

type ServiceAccount struct {
	CurrentNamespace string
	// contains filtered or unexported fields
}

ServiceAccount for manager namespace actions

func NewServiceAccountAction

func NewServiceAccountAction(client coreInterface.CoreV1Interface) *ServiceAccount

NewServiceAccountAction get ServiceAccount action

func (*ServiceAccount) Create

func (sa *ServiceAccount) Create(serviceAccount *apiv1.ServiceAccount) error

Create Create an ServiceAccount

func (*ServiceAccount) Delete

func (sa *ServiceAccount) Delete(saName string) error

Delete Delete a pod in the client

func (*ServiceAccount) Get

func (sa *ServiceAccount) Get(saName string) (*apiv1.ServiceAccount, error)

Get get namespace

func (*ServiceAccount) List

List List all pods in a namespace

func (*ServiceAccount) Namespace

func (sa *ServiceAccount) Namespace(namespace string) *ServiceAccount

Namespace set namespace

func (*ServiceAccount) Update

func (sa *ServiceAccount) Update(serviceAccount *apiv1.ServiceAccount) error

Update Update a pods in the client

Jump to

Keyboard shortcuts

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