Documentation ¶
Index ¶
- func CloneRepo(source string, destinationDir string) error
- func ParseK8sYaml(filepath string) ([]runtime.Object, []*schema.GroupVersionKind, error)
- type Cluster
- func (c *Cluster) ApplyFiles(source string, namespace string) error
- func (c *Cluster) ClusterName() (string, error)
- func (c *Cluster) CreateMachine(namespace string) error
- func (c *Cluster) CreateMachineDeployment(namespace string) error
- func (c *Cluster) DeleteResources(source string, namespace string) error
- func (c *Cluster) FillClientSets() error
- func (c *Cluster) GetNumberOfNodes() int16
- func (c *Cluster) GetNumberOfReadyNodes() int16
- func (c *Cluster) GetSecretData(machineClassName string, secretRefs ...*v1.SecretReference) (map[string][]byte, error)
- func (c *Cluster) IsSeed(target *Cluster) bool
- func (c *Cluster) IsTestMachineDeleted() bool
- func (c *Cluster) ProbeNodes() error
- type ResourcesTrackerInterface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CloneRepo ¶
CloneRepo clones github repo locally. This is required if there is no mcm container image tag supplied or the clusters are not seed (control) and shoot (target) clusters
func ParseK8sYaml ¶
ParseK8sYaml reads a yaml file and parses it based on the scheme
Types ¶
type Cluster ¶
type Cluster struct { Clientset *kubernetes.Clientset McmClient *mcmClientset.Clientset RbacClient *rbac.RbacV1Client KubeConfigFilePath string // contains filtered or unexported fields }
Cluster type to hold cluster specific details
func NewCluster ¶
NewCluster returns a Cluster struct
func (*Cluster) ApplyFiles ¶
ApplyFiles invokes ApplyFile on a each file
func (*Cluster) ClusterName ¶
ClusterName retrieves cluster name from the kubeconfig
func (*Cluster) CreateMachine ¶
CreateMachine creates a test-machine using machineclass "test-mc"
func (*Cluster) CreateMachineDeployment ¶
CreateMachineDeployment creates a test-machine-deployment with 3 replicas and returns error if it occurs
func (*Cluster) DeleteResources ¶
DeleteResources invokes DeleteResource on a each file
func (*Cluster) FillClientSets ¶
FillClientSets checks whether the cluster is accessible and returns an error if not
func (*Cluster) GetNumberOfNodes ¶
GetNumberOfNodes tries to retrieve the list of node objects in the cluster.
func (*Cluster) GetNumberOfReadyNodes ¶
GetNumberOfReadyNodes tries to retrieve the list of node objects in the cluster.
func (*Cluster) GetSecretData ¶
func (c *Cluster) GetSecretData(machineClassName string, secretRefs ...*v1.SecretReference) (map[string][]byte, error)
GetSecretData combines secrets
func (*Cluster) IsTestMachineDeleted ¶
IsTestMachineDeleted returns boolean value of presence of 'test-machine' object
func (*Cluster) ProbeNodes ¶
ProbeNodes tries to probe for nodes.
type ResourcesTrackerInterface ¶
type ResourcesTrackerInterface interface { IsOrphanedResourcesAvailable() bool InitializeResourcesTracker( machineClass *v1alpha1.MachineClass, secretData map[string][]byte, clusterName string, ) error }
ResourcesTrackerInterface provides an interface to check for orphan resources. The implementation should handle probing for resources while contructing or calling New method And reporting orphan resources whenever IsOrphanedResourcesAvailable is invoked