Documentation ¶
Index ¶
- func EksaChangeDiff(currentSpec, newSpec *cluster.Spec) *types.ChangeDiff
- func NewClient(clusterClient ClusterClient) *client
- func NewRetrierClient(client *client, retrier *retrier.Retrier) *retrierClient
- type AwsIamAuth
- type ClusterClient
- type ClusterManager
- func (c *ClusterManager) ApplyBundles(ctx context.Context, clusterSpec *cluster.Spec, cluster *types.Cluster) error
- func (c *ClusterManager) CreateAwsIamAuthCaSecret(ctx context.Context, cluster *types.Cluster) error
- func (c *ClusterManager) CreateEKSANamespace(ctx context.Context, cluster *types.Cluster) error
- func (c *ClusterManager) CreateEKSAResources(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, ...) error
- func (c *ClusterManager) CreateWorkloadCluster(ctx context.Context, managementCluster *types.Cluster, ...) (*types.Cluster, error)
- func (c *ClusterManager) DeleteAWSIamConfig(ctx context.Context, managementCluster *types.Cluster, name string, ...) error
- func (c *ClusterManager) DeleteCluster(ctx context.Context, managementCluster, clusterToDelete *types.Cluster, ...) error
- func (c *ClusterManager) DeleteEKSACluster(ctx context.Context, managementCluster *types.Cluster, name string, ...) error
- func (c *ClusterManager) DeleteGitOpsConfig(ctx context.Context, managementCluster *types.Cluster, name string, ...) error
- func (c *ClusterManager) DeleteOIDCConfig(ctx context.Context, managementCluster *types.Cluster, name string, ...) error
- func (c *ClusterManager) EKSAClusterSpecChanged(ctx context.Context, cluster *types.Cluster, newClusterSpec *cluster.Spec) (bool, error)
- func (c *ClusterManager) GetCurrentClusterSpec(ctx context.Context, clus *types.Cluster, clusterName string) (*cluster.Spec, error)
- func (c *ClusterManager) InstallAwsIamAuth(ctx context.Context, managementCluster, workloadCluster *types.Cluster, ...) error
- func (c *ClusterManager) InstallCAPI(ctx context.Context, clusterSpec *cluster.Spec, cluster *types.Cluster, ...) error
- func (c *ClusterManager) InstallCustomComponents(ctx context.Context, clusterSpec *cluster.Spec, cluster *types.Cluster, ...) error
- func (c *ClusterManager) InstallMachineHealthChecks(ctx context.Context, clusterSpec *cluster.Spec, workloadCluster *types.Cluster) error
- func (c *ClusterManager) InstallNetworking(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, ...) error
- func (c *ClusterManager) InstallStorageClass(ctx context.Context, cluster *types.Cluster, provider providers.Provider) error
- func (c *ClusterManager) MoveCAPI(ctx context.Context, from, to *types.Cluster, clusterName string, ...) error
- func (c *ClusterManager) PauseEKSAControllerReconcile(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, ...) error
- func (c *ClusterManager) ResumeEKSAControllerReconcile(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, ...) error
- func (c *ClusterManager) RunPostCreateWorkloadCluster(ctx context.Context, managementCluster, workloadCluster *types.Cluster, ...) error
- func (c *ClusterManager) SaveLogsManagementCluster(ctx context.Context, spec *cluster.Spec, cluster *types.Cluster) error
- func (c *ClusterManager) SaveLogsWorkloadCluster(ctx context.Context, provider providers.Provider, spec *cluster.Spec, ...) error
- func (c *ClusterManager) UpgradeCluster(ctx context.Context, managementCluster, workloadCluster *types.Cluster, ...) error
- func (c *ClusterManager) UpgradeNetworking(ctx context.Context, cluster *types.Cluster, ...) (*types.ChangeDiff, error)
- type ClusterManagerOpt
- type Networking
- type Upgrader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EksaChangeDiff ¶ added in v0.7.0
func EksaChangeDiff(currentSpec, newSpec *cluster.Spec) *types.ChangeDiff
func NewClient ¶ added in v0.6.0
func NewClient(clusterClient ClusterClient) *client
func NewRetrierClient ¶ added in v0.6.0
Types ¶
type AwsIamAuth ¶ added in v0.6.0
type ClusterClient ¶
type ClusterClient interface { MoveManagement(ctx context.Context, org, target *types.Cluster) error ApplyKubeSpecFromBytes(ctx context.Context, cluster *types.Cluster, data []byte) error ApplyKubeSpecFromBytesWithNamespace(ctx context.Context, cluster *types.Cluster, data []byte, namespace string) error ApplyKubeSpecFromBytesForce(ctx context.Context, cluster *types.Cluster, data []byte) error WaitForClusterReady(ctx context.Context, cluster *types.Cluster, timeout string, clusterName string) error WaitForControlPlaneReady(ctx context.Context, cluster *types.Cluster, timeout string, newClusterName string) error WaitForControlPlaneNotReady(ctx context.Context, cluster *types.Cluster, timeout string, newClusterName string) error WaitForManagedExternalEtcdReady(ctx context.Context, cluster *types.Cluster, timeout string, newClusterName string) error WaitForManagedExternalEtcdNotReady(ctx context.Context, cluster *types.Cluster, timeout string, newClusterName string) error GetWorkloadKubeconfig(ctx context.Context, clusterName string, cluster *types.Cluster) ([]byte, error) GetEksaGitOpsConfig(ctx context.Context, gitOpsConfigName string, kubeconfigFile string, namespace string) (*v1alpha1.GitOpsConfig, error) GetEksaFluxConfig(ctx context.Context, fluxConfigName string, kubeconfigFile string, namespace string) (*v1alpha1.FluxConfig, error) GetEksaOIDCConfig(ctx context.Context, oidcConfigName string, kubeconfigFile string, namespace string) (*v1alpha1.OIDCConfig, error) DeleteCluster(ctx context.Context, managementCluster, clusterToDelete *types.Cluster) error DeleteGitOpsConfig(ctx context.Context, managementCluster *types.Cluster, gitOpsName, namespace string) error DeleteOIDCConfig(ctx context.Context, managementCluster *types.Cluster, oidcConfigName, oidcConfigNamespace string) error DeleteAWSIamConfig(ctx context.Context, managementCluster *types.Cluster, awsIamConfigName, awsIamConfigNamespace string) error DeleteEKSACluster(ctx context.Context, managementCluster *types.Cluster, eksaClusterName, eksaClusterNamespace string) error InitInfrastructure(ctx context.Context, clusterSpec *cluster.Spec, cluster *types.Cluster, provider providers.Provider) error WaitForDeployment(ctx context.Context, cluster *types.Cluster, timeout string, condition string, target string, namespace string) error SaveLog(ctx context.Context, cluster *types.Cluster, deployment *types.Deployment, fileName string, writer filewriter.FileWriter) error GetMachines(ctx context.Context, cluster *types.Cluster, clusterName string) ([]types.Machine, error) GetClusters(ctx context.Context, cluster *types.Cluster) ([]types.CAPICluster, error) GetEksaCluster(ctx context.Context, cluster *types.Cluster, clusterName string) (*v1alpha1.Cluster, error) GetEksaVSphereDatacenterConfig(ctx context.Context, VSphereDatacenterName string, kubeconfigFile string, namespace string) (*v1alpha1.VSphereDatacenterConfig, error) UpdateEnvironmentVariablesInNamespace(ctx context.Context, resourceType, resourceName string, envMap map[string]string, cluster *types.Cluster, namespace string) error UpdateAnnotationInNamespace(ctx context.Context, resourceType, objectName string, annotations map[string]string, cluster *types.Cluster, namespace string) error RemoveAnnotationInNamespace(ctx context.Context, resourceType, objectName, key string, cluster *types.Cluster, namespace string) error GetEksaVSphereMachineConfig(ctx context.Context, VSphereDatacenterName string, kubeconfigFile string, namespace string) (*v1alpha1.VSphereMachineConfig, error) GetEksaCloudStackMachineConfig(ctx context.Context, cloudstackMachineConfigName string, kubeconfigFile string, namespace string) (*v1alpha1.CloudStackMachineConfig, error) SetEksaControllerEnvVar(ctx context.Context, envVar, envVarVal, kubeconfig string) error CreateNamespaceIfNotPresent(ctx context.Context, kubeconfig string, namespace string) error ValidateControlPlaneNodes(ctx context.Context, cluster *types.Cluster, clusterName string) error ValidateWorkerNodes(ctx context.Context, clusterName string, kubeconfigFile string) error CountMachineDeploymentReplicasReady(ctx context.Context, clusterName string, kubeconfigFile string) (int, int, error) GetBundles(ctx context.Context, kubeconfigFile, name, namespace string) (*releasev1alpha1.Bundles, error) GetApiServerUrl(ctx context.Context, cluster *types.Cluster) (string, error) GetClusterCATlsCert(ctx context.Context, clusterName string, cluster *types.Cluster, namespace string) ([]byte, error) KubeconfigSecretAvailable(ctx context.Context, kubeconfig string, clusterName string, namespace string) (bool, error) DeleteOldWorkerNodeGroup(ctx context.Context, machineDeployment *clusterv1.MachineDeployment, kubeconfig string) error GetMachineDeployment(ctx context.Context, workerNodeGroupName string, opts ...executables.KubectlOpt) (*clusterv1.MachineDeployment, error) GetEksdRelease(ctx context.Context, name, namespace, kubeconfigFile string) (*eksdv1alpha1.Release, error) }
type ClusterManager ¶
type ClusterManager struct { *Upgrader Retrier *retrier.Retrier // contains filtered or unexported fields }
func New ¶
func New(clusterClient ClusterClient, networking Networking, writer filewriter.FileWriter, diagnosticBundleFactory diagnostics.DiagnosticBundleFactory, awsIamAuth AwsIamAuth, maxWaitPerMachine time.Duration, opts ...ClusterManagerOpt) *ClusterManager
func (*ClusterManager) ApplyBundles ¶ added in v0.6.0
func (*ClusterManager) CreateAwsIamAuthCaSecret ¶ added in v0.6.0
func (*ClusterManager) CreateEKSANamespace ¶ added in v0.11.0
func (*ClusterManager) CreateEKSAResources ¶
func (c *ClusterManager) CreateEKSAResources(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, datacenterConfig providers.DatacenterConfig, machineConfigs []providers.MachineConfig, ) error
func (*ClusterManager) CreateWorkloadCluster ¶
func (c *ClusterManager) CreateWorkloadCluster(ctx context.Context, managementCluster *types.Cluster, clusterSpec *cluster.Spec, provider providers.Provider) (*types.Cluster, error)
CreateWorkloadCluster creates a workload cluster in the provider that the customer has specified. It applied the kubernetes manifest file on the management cluster, waits for the control plane to be ready, and then generates the kubeconfig for the cluster. It returns a struct of type Cluster containing the name and the kubeconfig of the cluster.
func (*ClusterManager) DeleteAWSIamConfig ¶ added in v0.6.0
func (*ClusterManager) DeleteCluster ¶
func (*ClusterManager) DeleteEKSACluster ¶ added in v0.6.0
func (*ClusterManager) DeleteGitOpsConfig ¶ added in v0.6.0
func (*ClusterManager) DeleteOIDCConfig ¶ added in v0.6.0
func (*ClusterManager) EKSAClusterSpecChanged ¶
func (*ClusterManager) GetCurrentClusterSpec ¶ added in v0.6.0
func (*ClusterManager) InstallAwsIamAuth ¶ added in v0.6.0
func (c *ClusterManager) InstallAwsIamAuth(ctx context.Context, managementCluster, workloadCluster *types.Cluster, clusterSpec *cluster.Spec) error
InstallAwsIamAuth applies the aws-iam-authenticator manifest based on cluster spec inputs. Generates a kubeconfig for interacting with the cluster with aws-iam-authenticator client.
func (*ClusterManager) InstallCAPI ¶ added in v0.6.0
func (*ClusterManager) InstallCustomComponents ¶
func (*ClusterManager) InstallMachineHealthChecks ¶
func (*ClusterManager) InstallNetworking ¶
func (*ClusterManager) InstallStorageClass ¶
func (*ClusterManager) PauseEKSAControllerReconcile ¶
func (*ClusterManager) ResumeEKSAControllerReconcile ¶
func (*ClusterManager) RunPostCreateWorkloadCluster ¶ added in v0.10.1
func (*ClusterManager) SaveLogsManagementCluster ¶ added in v0.6.0
func (*ClusterManager) SaveLogsWorkloadCluster ¶ added in v0.6.0
func (*ClusterManager) UpgradeCluster ¶
func (*ClusterManager) UpgradeNetworking ¶ added in v0.7.0
type ClusterManagerOpt ¶
type ClusterManagerOpt func(*ClusterManager)
func WithRetrier ¶ added in v0.6.0
func WithRetrier(retrier *retrier.Retrier) ClusterManagerOpt
func WithWaitForMachines ¶
func WithWaitForMachines(machineBackoff, machineMaxWait, machinesMinWait time.Duration) ClusterManagerOpt
type Networking ¶
type Networking interface { GenerateManifest(ctx context.Context, clusterSpec *cluster.Spec, namespaces []string) ([]byte, error) Upgrade(ctx context.Context, cluster *types.Cluster, currentSpec, newSpec *cluster.Spec, namespaces []string) (*types.ChangeDiff, error) RunPostControlPlaneUpgradeSetup(ctx context.Context, cluster *types.Cluster) error }
type Upgrader ¶ added in v0.6.0
type Upgrader struct {
// contains filtered or unexported fields
}
func NewUpgrader ¶ added in v0.6.0
func NewUpgrader(retrier *retrierClient) *Upgrader
Click to show internal directories.
Click to hide internal directories.