Documentation ¶
Index ¶
- Constants
- func AssertControlPlaneMachineRefExists(spec *ClusterSpec) error
- func AssertDatacenterConfigValid(spec *ClusterSpec) error
- func AssertEtcdMachineRefExists(spec *ClusterSpec) error
- func AssertK8SVersionNot120(spec *ClusterSpec) error
- func AssertMachineConfigNamespaceMatchesDatacenterConfig(spec *ClusterSpec) error
- func AssertMachineConfigsValid(spec *ClusterSpec) error
- func AssertOsFamilyValid(spec *ClusterSpec) error
- func AssertTinkerbellIPAndControlPlaneIPNotSame(spec *ClusterSpec) error
- func AssertWorkerNodeGroupMachineRefsExists(spec *ClusterSpec) error
- func GenerateNoProxyList(clusterSpec *v1alpha1.Cluster, ...) []string
- func GetMachineTemplate(ctx context.Context, client kubernetes.Client, name, namespace string) (*tinkerbellv1.TinkerbellMachineTemplate, error)
- func NewTemplateBuilder(datacenterSpec *v1alpha1.TinkerbellDatacenterConfigSpec, ...) providers.TemplateBuilder
- type BaseControlPlane
- type ClusterSpec
- func (s *ClusterSpec) ControlPlaneConfiguration() *v1alpha1.ControlPlaneConfiguration
- func (s *ClusterSpec) ControlPlaneMachineConfig() *v1alpha1.TinkerbellMachineConfig
- func (s *ClusterSpec) ExternalEtcdConfiguration() *v1alpha1.ExternalEtcdConfiguration
- func (s *ClusterSpec) ExternalEtcdMachineConfig() *v1alpha1.TinkerbellMachineConfig
- func (s *ClusterSpec) HasExternalEtcd() bool
- func (s *ClusterSpec) WorkerNodeGroupConfigurations() []v1alpha1.WorkerNodeGroupConfiguration
- func (s *ClusterSpec) WorkerNodeGroupMachineConfig(conf v1alpha1.WorkerNodeGroupConfiguration) *v1alpha1.TinkerbellMachineConfig
- type ClusterSpecAssertion
- func AssertPortsNotInUse(client networkutils.NetClient) ClusterSpecAssertion
- func AssertTinkerbellIPNotInUse(client networkutils.NetClient) ClusterSpecAssertion
- func AssertionsForScaleUpDown(catalogue *hardware.Catalogue, current ValidatableCluster, rollingUpgrade bool) ClusterSpecAssertion
- func ExtraHardwareAvailableAssertionForRollingUpgrade(catalogue *hardware.Catalogue) ClusterSpecAssertion
- func HardwareSatisfiesOnlyOneSelectorAssertion(catalogue *hardware.Catalogue) ClusterSpecAssertion
- func MinimumHardwareAvailableAssertionForCreate(catalogue *hardware.Catalogue) ClusterSpecAssertion
- func NewIPNotInUseAssertion(client networkutils.NetClient) ClusterSpecAssertion
- type ClusterSpecValidator
- type ControlPlane
- type Provider
- func (p *Provider) BootstrapClusterOpts(_ *cluster.Spec) ([]bootstrapper.BootstrapClusterOption, error)
- func (p *Provider) ChangeDiff(currentSpec, newSpec *cluster.Spec) *types.ComponentChangeDiff
- func (p *Provider) DatacenterConfig(_ *cluster.Spec) providers.DatacenterConfig
- func (p *Provider) DatacenterResourceType() string
- func (p *Provider) DeleteResources(ctx context.Context, clusterSpec *cluster.Spec) error
- func (p *Provider) EnvMap(spec *cluster.Spec) (map[string]string, error)
- func (p *Provider) GenerateCAPISpecForCreate(ctx context.Context, _ *types.Cluster, clusterSpec *cluster.Spec) (controlPlaneSpec, workersSpec []byte, err error)
- func (p *Provider) GenerateCAPISpecForUpgrade(ctx context.Context, bootstrapCluster, workloadCluster *types.Cluster, ...) (controlPlaneSpec, workersSpec []byte, err error)
- func (p *Provider) GetDeployments() map[string][]string
- func (p *Provider) GetInfrastructureBundle(clusterSpec *cluster.Spec) *types.InfrastructureBundle
- func (p *Provider) InstallCustomProviderComponents(ctx context.Context, kubeconfigFile string) error
- func (p *Provider) MachineConfigs(_ *cluster.Spec) []providers.MachineConfig
- func (p *Provider) MachineResourceType() string
- func (p *Provider) Name() string
- func (p *Provider) PostBootstrapDeleteForUpgrade(ctx context.Context) error
- func (p *Provider) PostBootstrapSetup(ctx context.Context, clusterConfig *v1alpha1.Cluster, cluster *types.Cluster) error
- func (p *Provider) PostBootstrapSetupUpgrade(ctx context.Context, clusterConfig *v1alpha1.Cluster, cluster *types.Cluster) error
- func (p *Provider) PostClusterDeleteValidate(ctx context.Context, managementCluster *types.Cluster) error
- func (p *Provider) PostMoveManagementToBootstrap(ctx context.Context, bootstrapCluster *types.Cluster) error
- func (p *Provider) PostWorkloadInit(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error
- func (p *Provider) PreCAPIInstallOnBootstrap(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error
- func (p *Provider) PreCoreComponentsUpgrade(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error
- func (p *Provider) RunPostControlPlaneUpgrade(ctx context.Context, oldClusterSpec *cluster.Spec, clusterSpec *cluster.Spec, ...) error
- func (p *Provider) SetupAndValidateCreateCluster(ctx context.Context, clusterSpec *cluster.Spec) error
- func (p *Provider) SetupAndValidateDeleteCluster(ctx context.Context, cluster *types.Cluster, _ *cluster.Spec) error
- func (p *Provider) SetupAndValidateUpgradeCluster(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, ...) error
- func (p *Provider) UpdateKubeConfig(content *[]byte, clusterName string) error
- func (p *Provider) UpdateSecrets(ctx context.Context, cluster *types.Cluster, _ *cluster.Spec) error
- func (p *Provider) UpgradeNeeded(_ context.Context, _, _ *cluster.Spec, _ *types.Cluster) (bool, error)
- func (p *Provider) ValidateNewSpec(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error
- func (p *Provider) Version(clusterSpec *cluster.Spec) string
- type ProviderKubectlClient
- type SSHAuthKeyGenerator
- type TemplateBuilder
- type ValidatableCluster
- type ValidatableTinkerbellCAPI
- type ValidatableTinkerbellClusterSpec
- type WorkerNodeHardware
- type Workers
Constants ¶
const (
TinkerbellMachineTemplateKind = "TinkerbellMachineTemplate"
)
Variables ¶
This section is empty.
Functions ¶
func AssertControlPlaneMachineRefExists ¶ added in v0.9.1
func AssertControlPlaneMachineRefExists(spec *ClusterSpec) error
AssertControlPlaneMachineRefExists ensures the control plane machine ref is referencing a known machine config.
func AssertDatacenterConfigValid ¶ added in v0.9.1
func AssertDatacenterConfigValid(spec *ClusterSpec) error
AssertDatacenterConfigValid asserts the DatacenterConfig in spec is valid.
func AssertEtcdMachineRefExists ¶ added in v0.9.1
func AssertEtcdMachineRefExists(spec *ClusterSpec) error
AssertEtcdMachineRefExists ensures that, if the etcd configuration is specified, it references a known machine config.
func AssertK8SVersionNot120 ¶ added in v0.11.0
func AssertK8SVersionNot120(spec *ClusterSpec) error
AssertK8SVersionNot120 ensures Kubernetes version is not set to v1.20.
func AssertMachineConfigNamespaceMatchesDatacenterConfig ¶ added in v0.9.1
func AssertMachineConfigNamespaceMatchesDatacenterConfig(spec *ClusterSpec) error
AssertMachineConfigNamespaceMatchesDatacenterConfig ensures all machine configuration instances are configured with the same namespace as the provider specific data center configuration namespace.
func AssertMachineConfigsValid ¶ added in v0.9.1
func AssertMachineConfigsValid(spec *ClusterSpec) error
AssertMachineConfigsValid iterates over all machine configs in calling validateMachineConfig.
func AssertOsFamilyValid ¶ added in v0.11.0
func AssertOsFamilyValid(spec *ClusterSpec) error
func AssertTinkerbellIPAndControlPlaneIPNotSame ¶ added in v0.12.0
func AssertTinkerbellIPAndControlPlaneIPNotSame(spec *ClusterSpec) error
AssertTinkerbellIPAndControlPlaneIPNotSame ensures tinkerbell ip and controlplane ip are not the same.
func AssertWorkerNodeGroupMachineRefsExists ¶ added in v0.9.1
func AssertWorkerNodeGroupMachineRefsExists(spec *ClusterSpec) error
AssertWorkerNodeGroupMachineRefsExists ensures all worker node group machine refs are referencing a known machine config.
func GenerateNoProxyList ¶ added in v0.15.0
func GenerateNoProxyList(clusterSpec *v1alpha1.Cluster, datacenterSpec v1alpha1.TinkerbellDatacenterConfigSpec, tinkerbellIP string) []string
GenerateNoProxyList generates NOPROXY list for tinkerbell provider based on HTTP_PROXY, HTTPS_PROXY, NOPROXY and tinkerbellIP.
func GetMachineTemplate ¶ added in v0.15.0
func GetMachineTemplate(ctx context.Context, client kubernetes.Client, name, namespace string) (*tinkerbellv1.TinkerbellMachineTemplate, error)
GetMachineTemplate gets a TinkerbellMachineTemplate object using the provided client If the object doesn't exist, it returns a NotFound error.
func NewTemplateBuilder ¶ added in v0.9.2
func NewTemplateBuilder(datacenterSpec *v1alpha1.TinkerbellDatacenterConfigSpec, controlPlaneMachineSpec, etcdMachineSpec *v1alpha1.TinkerbellMachineConfigSpec, workerNodeGroupMachineSpecs map[string]v1alpha1.TinkerbellMachineConfigSpec, tinkerbellIP string, now types.NowFunc) providers.TemplateBuilder
NewTemplateBuilder creates a new TemplateBuilder instance.
Types ¶
type BaseControlPlane ¶ added in v0.15.0
type BaseControlPlane = clusterapi.ControlPlane[*tinkerbellv1.TinkerbellCluster, *tinkerbellv1.TinkerbellMachineTemplate]
BaseControlPlane represents a CAPI Tinkerbell control plane.
type ClusterSpec ¶ added in v0.9.1
type ClusterSpec struct { *cluster.Spec // DatacenterConfig configured in the cluster configuration YAML. DatacenterConfig *v1alpha1.TinkerbellDatacenterConfig // MachineConfigs configured in the cluster configuration YAML whether they're used or not. MachineConfigs map[string]*v1alpha1.TinkerbellMachineConfig }
ClusterSpec represents a cluster configuration for Tinkerbell provisioning.
func NewClusterSpec ¶ added in v0.9.1
func NewClusterSpec( clusterSpec *cluster.Spec, machineConfigs map[string]*v1alpha1.TinkerbellMachineConfig, datacenterConfig *v1alpha1.TinkerbellDatacenterConfig, ) *ClusterSpec
NewClusterSpec creates a ClusterSpec instance.
func (*ClusterSpec) ControlPlaneConfiguration ¶ added in v0.9.2
func (s *ClusterSpec) ControlPlaneConfiguration() *v1alpha1.ControlPlaneConfiguration
ControlPlaneConfiguration retrieves the control plane configuration from s.
func (*ClusterSpec) ControlPlaneMachineConfig ¶ added in v0.9.1
func (s *ClusterSpec) ControlPlaneMachineConfig() *v1alpha1.TinkerbellMachineConfig
ControlPlaneMachineConfig retrieves the TinkerbellMachineConfig referenced by the cluster control plane machine reference.
func (*ClusterSpec) ExternalEtcdConfiguration ¶ added in v0.9.2
func (s *ClusterSpec) ExternalEtcdConfiguration() *v1alpha1.ExternalEtcdConfiguration
ExternalEtcdConfiguration returns the etcd configuration. The configuration may be nil. Consumers should check if external etcd configuration is present using HasExternalEtcd().
func (*ClusterSpec) ExternalEtcdMachineConfig ¶ added in v0.9.2
func (s *ClusterSpec) ExternalEtcdMachineConfig() *v1alpha1.TinkerbellMachineConfig
ExternalEtcdMachineConfig retrieves the TinkerbellMachineConfig referenced by the cluster etcd machine reference.
func (*ClusterSpec) HasExternalEtcd ¶ added in v0.9.1
func (s *ClusterSpec) HasExternalEtcd() bool
HasExternalEtcd returns true if there is an external etcd configuration.
func (*ClusterSpec) WorkerNodeGroupConfigurations ¶ added in v0.9.2
func (s *ClusterSpec) WorkerNodeGroupConfigurations() []v1alpha1.WorkerNodeGroupConfiguration
WorkerNodeGroupConfigurations retrieves all worker node group configurations in s.
func (*ClusterSpec) WorkerNodeGroupMachineConfig ¶ added in v0.9.2
func (s *ClusterSpec) WorkerNodeGroupMachineConfig(conf v1alpha1.WorkerNodeGroupConfiguration) *v1alpha1.TinkerbellMachineConfig
WorkerNodeGroupMachineConfig retrieves the machine group associated with conf.
type ClusterSpecAssertion ¶ added in v0.9.1
type ClusterSpecAssertion func(spec *ClusterSpec) error
ClusterSpecAssertion makes an assertion on spec.
func AssertPortsNotInUse ¶ added in v0.12.0
func AssertPortsNotInUse(client networkutils.NetClient) ClusterSpecAssertion
AssertPortsNotInUse ensures that ports 80, 42113, and 50061 are available.
func AssertTinkerbellIPNotInUse ¶ added in v0.12.0
func AssertTinkerbellIPNotInUse(client networkutils.NetClient) ClusterSpecAssertion
AssertTinkerbellIPNotInUse ensures tinkerbell ip isn't in use.
func AssertionsForScaleUpDown ¶ added in v0.11.0
func AssertionsForScaleUpDown(catalogue *hardware.Catalogue, current ValidatableCluster, rollingUpgrade bool) ClusterSpecAssertion
AssertionsForScaleUpDown asserts that catalogue has sufficient hardware to support the scaling up/down from current ClusterSpec to desired ValidatableCluster. nolint:gocyclo // TODO: Reduce cyclomatic complexity https://github.com/aws/eks-anywhere-internal/issues/1186
func ExtraHardwareAvailableAssertionForRollingUpgrade ¶ added in v0.11.0
func ExtraHardwareAvailableAssertionForRollingUpgrade(catalogue *hardware.Catalogue) ClusterSpecAssertion
ExtraHardwareAvailableAssertionForRollingUpgrade asserts that catalogue has sufficient hardware to support the ClusterSpec during an rolling upgrade workflow.
func HardwareSatisfiesOnlyOneSelectorAssertion ¶ added in v0.9.2
func HardwareSatisfiesOnlyOneSelectorAssertion(catalogue *hardware.Catalogue) ClusterSpecAssertion
HardwareSatisfiesOnlyOneSelectorAssertion ensures hardware in catalogue only satisfies 1 of the MachineConfig's HardwareSelector's from the spec.
func MinimumHardwareAvailableAssertionForCreate ¶ added in v0.9.2
func MinimumHardwareAvailableAssertionForCreate(catalogue *hardware.Catalogue) ClusterSpecAssertion
MinimumHardwareAvailableAssertionForCreate asserts that catalogue has sufficient hardware to support the ClusterSpec during a create workflow.
It does not protect against intersections or subsets so consumers should ensure a 1-2-1 mapping between catalogue hardware and selectors.
func NewIPNotInUseAssertion ¶ added in v0.9.1
func NewIPNotInUseAssertion(client networkutils.NetClient) ClusterSpecAssertion
AssertcontrolPlaneIPNotInUse ensures the endpoint host for the control plane isn't in use. The check may be unreliable due to its implementation.
type ClusterSpecValidator ¶ added in v0.9.1
type ClusterSpecValidator []ClusterSpecAssertion
ClusterSpecValidator is composed of a set of ClusterSpecAssertions to be run on a ClusterSpec instance.
func NewClusterSpecValidator ¶ added in v0.9.1
func NewClusterSpecValidator(assertions ...ClusterSpecAssertion) *ClusterSpecValidator
NewClusterSpecValidator creates a ClusterSpecValidator instance with a set of default assertions. Any assertions passed will be registered in addition to the default assertions.
func (*ClusterSpecValidator) Register ¶ added in v0.9.1
func (v *ClusterSpecValidator) Register(assertions ...ClusterSpecAssertion)
Register registers assertions with v.
func (*ClusterSpecValidator) Validate ¶ added in v0.9.1
func (v *ClusterSpecValidator) Validate(spec *ClusterSpec) error
Validate validates spec with all assertions registered on v.
type ControlPlane ¶ added in v0.15.0
type ControlPlane struct { BaseControlPlane Secrets *corev1.Secret }
ControlPlane holds the Tinkerbell specific objects for a CAPI Tinkerbell control plane.
func ControlPlaneSpec ¶ added in v0.15.0
func ControlPlaneSpec(ctx context.Context, logger logr.Logger, client kubernetes.Client, clusterSpec *cluster.Spec) (*ControlPlane, error)
ControlPlaneSpec builds a Tinkerbell ControlPlane definition based on an eks-a cluster spec.
func (ControlPlane) Objects ¶ added in v0.15.0
func (p ControlPlane) Objects() []kubernetes.Object
Objects returns the control plane objects associated with the Tinkerbell cluster.
type Provider ¶ added in v0.9.0
type Provider struct {
// contains filtered or unexported fields
}
func NewProvider ¶
func NewProvider( datacenterConfig *v1alpha1.TinkerbellDatacenterConfig, machineConfigs map[string]*v1alpha1.TinkerbellMachineConfig, clusterConfig *v1alpha1.Cluster, hardwareCSVPath string, writer filewriter.FileWriter, docker stack.Docker, helm stack.Helm, providerKubectlClient ProviderKubectlClient, tinkerbellIP string, now types.NowFunc, forceCleanup bool, skipIpCheck bool, ) (*Provider, error)
func (*Provider) BootstrapClusterOpts ¶ added in v0.9.0
func (p *Provider) BootstrapClusterOpts(_ *cluster.Spec) ([]bootstrapper.BootstrapClusterOption, error)
func (*Provider) ChangeDiff ¶ added in v0.9.0
func (p *Provider) ChangeDiff(currentSpec, newSpec *cluster.Spec) *types.ComponentChangeDiff
func (*Provider) DatacenterConfig ¶ added in v0.9.0
func (p *Provider) DatacenterConfig(_ *cluster.Spec) providers.DatacenterConfig
func (*Provider) DatacenterResourceType ¶ added in v0.9.0
func (*Provider) DeleteResources ¶ added in v0.9.0
func (*Provider) GenerateCAPISpecForCreate ¶ added in v0.9.0
func (*Provider) GenerateCAPISpecForUpgrade ¶ added in v0.9.0
func (*Provider) GetDeployments ¶ added in v0.9.0
func (*Provider) GetInfrastructureBundle ¶ added in v0.9.0
func (p *Provider) GetInfrastructureBundle(clusterSpec *cluster.Spec) *types.InfrastructureBundle
func (*Provider) InstallCustomProviderComponents ¶ added in v0.9.0
func (*Provider) MachineConfigs ¶ added in v0.9.0
func (p *Provider) MachineConfigs(_ *cluster.Spec) []providers.MachineConfig
func (*Provider) MachineResourceType ¶ added in v0.9.0
func (*Provider) PostBootstrapDeleteForUpgrade ¶ added in v0.11.0
func (*Provider) PostBootstrapSetup ¶ added in v0.9.0
func (*Provider) PostBootstrapSetupUpgrade ¶ added in v0.9.2
func (*Provider) PostClusterDeleteValidate ¶ added in v0.9.0
func (*Provider) PostMoveManagementToBootstrap ¶ added in v0.12.0
func (*Provider) PostWorkloadInit ¶ added in v0.9.2
func (*Provider) PreCAPIInstallOnBootstrap ¶ added in v0.9.0
func (*Provider) PreCoreComponentsUpgrade ¶ added in v0.15.0
func (p *Provider) PreCoreComponentsUpgrade( ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, ) error
PreCoreComponentsUpgrade staisfies the Provider interface.
func (*Provider) RunPostControlPlaneUpgrade ¶ added in v0.9.0
func (*Provider) SetupAndValidateCreateCluster ¶ added in v0.9.0
func (*Provider) SetupAndValidateDeleteCluster ¶ added in v0.9.0
func (*Provider) SetupAndValidateUpgradeCluster ¶ added in v0.9.0
func (*Provider) UpdateKubeConfig ¶ added in v0.9.0
func (*Provider) UpdateSecrets ¶ added in v0.9.0
func (*Provider) UpgradeNeeded ¶ added in v0.9.0
func (*Provider) ValidateNewSpec ¶ added in v0.9.0
type ProviderKubectlClient ¶
type ProviderKubectlClient interface { ApplyKubeSpecFromBytesForce(ctx context.Context, cluster *types.Cluster, data []byte) error ApplyKubeSpecFromBytesWithNamespace(ctx context.Context, cluster *types.Cluster, data []byte, namespace string) error DeleteEksaDatacenterConfig(ctx context.Context, eksaTinkerbellDatacenterResourceType string, tinkerbellDatacenterConfigName string, kubeconfigFile string, namespace string) error DeleteEksaMachineConfig(ctx context.Context, eksaTinkerbellMachineResourceType string, tinkerbellMachineConfigName string, kubeconfigFile string, namespace string) error GetMachineDeployment(ctx context.Context, machineDeploymentName string, opts ...executables.KubectlOpt) (*clusterv1.MachineDeployment, error) GetEksaCluster(ctx context.Context, cluster *types.Cluster, clusterName string) (*v1alpha1.Cluster, error) GetEksaTinkerbellDatacenterConfig(ctx context.Context, tinkerbellDatacenterConfigName string, kubeconfigFile string, namespace string) (*v1alpha1.TinkerbellDatacenterConfig, error) GetEksaTinkerbellMachineConfig(ctx context.Context, tinkerbellMachineConfigName string, kubeconfigFile string, namespace string) (*v1alpha1.TinkerbellMachineConfig, error) GetKubeadmControlPlane(ctx context.Context, cluster *types.Cluster, clusterName string, opts ...executables.KubectlOpt) (*controlplanev1.KubeadmControlPlane, error) GetEtcdadmCluster(ctx context.Context, cluster *types.Cluster, clusterName string, opts ...executables.KubectlOpt) (*etcdv1.EtcdadmCluster, error) GetSecret(ctx context.Context, secretObjectName string, opts ...executables.KubectlOpt) (*corev1.Secret, error) UpdateAnnotation(ctx context.Context, resourceType, objectName string, annotations map[string]string, opts ...executables.KubectlOpt) error WaitForDeployment(ctx context.Context, cluster *types.Cluster, timeout string, condition string, target string, namespace string) error GetUnprovisionedTinkerbellHardware(_ context.Context, kubeconfig, namespace string) ([]tinkv1alpha1.Hardware, error) GetProvisionedTinkerbellHardware(_ context.Context, kubeconfig, namespace string) ([]tinkv1alpha1.Hardware, error) WaitForRufioMachines(ctx context.Context, cluster *types.Cluster, timeout string, condition string, namespace string) error SearchTinkerbellMachineConfig(ctx context.Context, name string, kubeconfigFile string, namespace string) ([]*v1alpha1.TinkerbellMachineConfig, error) SearchTinkerbellDatacenterConfig(ctx context.Context, name string, kubeconfigFile string, namespace string) ([]*v1alpha1.TinkerbellDatacenterConfig, error) AllTinkerbellHardware(ctx context.Context, kuebconfig string) ([]tinkv1alpha1.Hardware, error) AllBaseboardManagements(ctx context.Context, kubeconfig string) ([]rufiounreleased.BaseboardManagement, error) HasCRD(ctx context.Context, kubeconfig, crd string) (bool, error) DeleteCRD(ctx context.Context, kubeconfig, crd string) error }
type SSHAuthKeyGenerator ¶ added in v0.8.0
type SSHAuthKeyGenerator interface {
GenerateSSHAuthKey(filewriter.FileWriter) (string, error)
}
KeyGenerator generates ssh keys and writes them to a FileWriter.
type TemplateBuilder ¶ added in v0.9.2
type TemplateBuilder struct { WorkerNodeGroupMachineSpecs map[string]v1alpha1.TinkerbellMachineConfigSpec // contains filtered or unexported fields }
func (*TemplateBuilder) GenerateCAPISpecControlPlane ¶ added in v0.9.2
func (tb *TemplateBuilder) GenerateCAPISpecControlPlane(clusterSpec *cluster.Spec, buildOptions ...providers.BuildMapOption) (content []byte, err error)
func (*TemplateBuilder) GenerateCAPISpecWorkers ¶ added in v0.9.2
type ValidatableCluster ¶ added in v0.15.0
type ValidatableCluster interface { // WorkerNodeHardwareGroups retrieves a list of WorkerNodeHardwares containing MachineDeployment name, // replica count and hardware selector for each worker node of a ValidatableCluster. WorkerNodeHardwareGroups() []WorkerNodeHardware // ControlPlaneReplicaCount retrieves the control plane replica count of the ValidatableCluster. ControlPlaneReplicaCount() int }
ValidatableCluster allows assertions to pull worker node and control plane information.
type ValidatableTinkerbellCAPI ¶ added in v0.15.0
type ValidatableTinkerbellCAPI struct { KubeadmControlPlane *controlplanev1.KubeadmControlPlane WorkerGroups []*clusterapi.WorkerGroup[*tinkerbellv1.TinkerbellMachineTemplate] }
ValidatableTinkerbellCAPI wraps around the Tinkerbell control plane and worker CAPI obects as a ValidatableCluster.
func (*ValidatableTinkerbellCAPI) ControlPlaneReplicaCount ¶ added in v0.15.0
func (v *ValidatableTinkerbellCAPI) ControlPlaneReplicaCount() int
ControlPlaneReplicaCount retrieves the ValidatableTinkerbellCAPI control plane replica count.
func (*ValidatableTinkerbellCAPI) WorkerNodeHardwareGroups ¶ added in v0.15.0
func (v *ValidatableTinkerbellCAPI) WorkerNodeHardwareGroups() []WorkerNodeHardware
WorkerNodeHardwareGroups retrieves a list of WorkerNodeHardwares for a ValidatableTinkerbellCAPI.
type ValidatableTinkerbellClusterSpec ¶ added in v0.15.0
type ValidatableTinkerbellClusterSpec struct {
*ClusterSpec
}
ValidatableTinkerbellClusterSpec wraps around the Tinkerbell ClusterSpec as a ValidatableCluster.
func (*ValidatableTinkerbellClusterSpec) ControlPlaneReplicaCount ¶ added in v0.15.0
func (v *ValidatableTinkerbellClusterSpec) ControlPlaneReplicaCount() int
ControlPlaneReplicaCount retrieves the ValidatableTinkerbellClusterSpec control plane replica count.
func (*ValidatableTinkerbellClusterSpec) WorkerNodeHardwareGroups ¶ added in v0.15.0
func (v *ValidatableTinkerbellClusterSpec) WorkerNodeHardwareGroups() []WorkerNodeHardware
WorkerNodeHardwareGroups retrieves a list of WorkerNodeHardwares for a ValidatableTinkerbellClusterSpec.
type WorkerNodeHardware ¶ added in v0.15.0
WorkerNodeHardware holds machine deployment name, replica count and hardware selector for a Tinkerbell worker node.
type Workers ¶ added in v0.15.0
type Workers = clusterapi.Workers[*tinkerbellv1.TinkerbellMachineTemplate]
Workers represents the Tinkerbell specific CAPI spec for worker nodes.
func WorkersSpec ¶ added in v0.15.0
func WorkersSpec(ctx context.Context, logger logr.Logger, client kubernetes.Client, spec *cluster.Spec) (*Workers, error)
WorkersSpec generates a Tinkerbell specific CAPI spec for an eks-a cluster worker nodes. It talks to the cluster with a client to detect changes in immutable objects and generates new names for them.
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |
Package rufiounreleased contains types that never became a formal release but were included in EKSA releases.
|
Package rufiounreleased contains types that never became a formal release but were included in EKSA releases. |
mocks
Package mocks is a generated GoMock package.
|
Package mocks is a generated GoMock package. |