k8s

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2020 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CNIDirectories = v1alpha1.VrouterCNIDirectories{
	BinariesDirectory:    "/opt/cni/bin",
	ConfigFilesDirectory: "/etc/cni",
}

CNIDirectories is struct with directories containing CNI specific files for k8s cluster

Functions

This section is empty.

Types

type CSRSignerCA

type CSRSignerCA struct {
	Client typedCorev1.CoreV1Interface
}

CSRSignerCA implements ManagerCSSignerCA interface used for for gathering the Certificate Authorities' certificates that sign the CertificateSigningRequests.

func (CSRSignerCA) CACert

func (c CSRSignerCA) CACert() (string, error)

CACert returns the value of certificates used for signing the CertificateSigningRequests On a k8s cluster, it is assumed that all certificates created inside the cluster are signed using the root CA, that is also attached to each one of the ServiceAccounts in the cluster

func (CSRSignerCA) GetServiceAccountTokenSecret

func (c CSRSignerCA) GetServiceAccountTokenSecret(serviceAccount *corev1.ServiceAccount) (*corev1.Secret, error)

type ClusterConfig

type ClusterConfig struct {
	Client typedCorev1.CoreV1Interface
}

ClusterConfig is a struct that incorporates v1alpha1.KubemanagerClusterInfo interface

func (ClusterConfig) KubernetesAPISSLPort

func (c ClusterConfig) KubernetesAPISSLPort() (int, error)

KubernetesAPISSLPort gathers SSL Port from Kubernetes Cluster via kubeadm-config ConfigMap

func (ClusterConfig) KubernetesAPIServer

func (c ClusterConfig) KubernetesAPIServer() (string, error)

KubernetesAPIServer gathers API Server from Kubernetes Cluster via kubeadm-config ConfigMap

func (ClusterConfig) KubernetesClusterName

func (c ClusterConfig) KubernetesClusterName() (string, error)

KubernetesClusterName gathers cluster name from Kubernetes Cluster via kubeadm-config ConfigMap

func (ClusterConfig) PodSubnets

func (c ClusterConfig) PodSubnets() (string, error)

PodSubnets gathers pods' subnet from Kubernetes Cluster via kubeadm-config ConfigMap

func (ClusterConfig) ServiceSubnets

func (c ClusterConfig) ServiceSubnets() (string, error)

ServiceSubnets gathers service subnet from Kubernetes Cluster via kubeadm-config ConfigMap

type ConfigMap

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

ConfigMap is used to create and modify config maps to configure owner

func (*ConfigMap) EnsureExists

func (c *ConfigMap) EnsureExists(dataSetter configMapFiller) error

EnsureExist is used to ensure that specific config map exists and is filled properly

type Kubernetes

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

Kubernetes is used to create and update meaningful objects

func New

func New(client client.Client, scheme *runtime.Scheme) *Kubernetes

New is used to create a new Kubernetes

func (*Kubernetes) ConfigMap

func (k *Kubernetes) ConfigMap(name, ownerType string, owner v1.Object) *ConfigMap

ConfigMap is used to create ConfigMap object

func (*Kubernetes) Owner

func (k *Kubernetes) Owner(owner object) *Owner

Owner is used to create Owner object

func (*Kubernetes) Secret

func (k *Kubernetes) Secret(name, ownerType string, owner v1.Object) *Secret

Secret is used to create Secret object

type Owner

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

Owner is used to manipulate Kubernetes's owner relationships

func (Owner) EnsureOwns

func (o Owner) EnsureOwns(dependent object) error

EnsureOwns is used to ensure that relation between owner and dependent object exist

type Secret

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

func (*Secret) EnsureExists

func (s *Secret) EnsureExists(dataSetter SecretFiller) error

type SecretFiller

type SecretFiller interface {
	FillSecret(sc *core.Secret) error
}

Jump to

Keyboard shortcuts

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