names

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package names implements name generators for managed topology.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BootstrapConfigNamePrefix added in v1.7.0

func BootstrapConfigNamePrefix(clusterName, machinePoolTopologyName string) string

BootstrapConfigNamePrefix calculates the name prefix for a BootstrapConfig.

func BootstrapTemplateNamePrefix added in v1.7.0

func BootstrapTemplateNamePrefix(clusterName, machineDeploymentTopologyName string) string

BootstrapTemplateNamePrefix calculates the name prefix for a BootstrapTemplate.

func ControlPlaneInfrastructureMachineTemplateNamePrefix added in v1.7.0

func ControlPlaneInfrastructureMachineTemplateNamePrefix(clusterName string) string

ControlPlaneInfrastructureMachineTemplateNamePrefix calculates the name prefix for a InfrastructureMachineTemplate.

func InfrastructureMachinePoolNamePrefix added in v1.7.0

func InfrastructureMachinePoolNamePrefix(clusterName, machinePoolTopologyName string) string

InfrastructureMachinePoolNamePrefix calculates the name prefix for a InfrastructureMachinePool.

func InfrastructureMachineTemplateNamePrefix added in v1.7.0

func InfrastructureMachineTemplateNamePrefix(clusterName, machineDeploymentTopologyName string) string

InfrastructureMachineTemplateNamePrefix calculates the name prefix for a InfrastructureMachineTemplate.

Types

type NameGenerator

type NameGenerator interface {
	// GenerateName generates a valid name. The generator is responsible for
	// knowing the maximum valid name length.
	GenerateName() (string, error)
}

NameGenerator generates names for objects.

func ControlPlaneNameGenerator

func ControlPlaneNameGenerator(templateString, clusterName string) NameGenerator

ControlPlaneNameGenerator returns a generator for creating a control plane name.

func MachineDeploymentNameGenerator

func MachineDeploymentNameGenerator(templateString, clusterName, topologyName string) NameGenerator

MachineDeploymentNameGenerator returns a generator for creating a machinedeployment name.

func MachinePoolNameGenerator added in v1.6.0

func MachinePoolNameGenerator(templateString, clusterName, topologyName string) NameGenerator

MachinePoolNameGenerator returns a generator for creating a machinepool name.

func SimpleNameGenerator

func SimpleNameGenerator(base string) NameGenerator

SimpleNameGenerator returns a NameGenerator which is based on k8s.io/apiserver/pkg/storage/names.SimpleNameGenerator.

Jump to

Keyboard shortcuts

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