Documentation
¶
Overview ¶
Package transformer provides a mechanism to transform node specification based on node transformation rules.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenericFuncMap ¶
GenericFuncMap returns a copy of the basic function map as a map[string]any.
Types ¶
type NodeFeaturesFlagSpec ¶
type NodeFeaturesFlagSpec struct {
// PublicIPDiscovery try to find public IP on the node
PublicIPDiscovery bool `yaml:"publicIPDiscovery,omitempty"`
}
NodeFeaturesFlagSpec represents the node features flags.
type NodeSpec ¶
type NodeSpec struct {
Annotations map[string]string
Labels map[string]string
Taints map[string]string
Features NodeFeaturesFlagSpec
}
NodeSpec represents the transformed node specifications.
func TransformNode ¶
func TransformNode(terms []NodeTerm, platformMetadata *runtime.PlatformMetadataSpec, sysinfo *hardware.SystemInformationSpec) (*NodeSpec, error)
TransformNode transforms the node metadata based on the node transformation rules.
type NodeTerm ¶
type NodeTerm struct {
Name string `yaml:"name,omitempty"`
NodeSelector []nodeselector.NodeSelectorTerm `yaml:"nodeSelector,omitempty"`
Annotations map[string]string `yaml:"annotations,omitempty"`
Labels map[string]string `yaml:"labels,omitempty"`
Taints map[string]string `yaml:"taints,omitempty"`
PlatformMetadata map[string]string `yaml:"platformMetadata,omitempty"`
Features NodeFeaturesFlagSpec `yaml:"features,omitempty"`
}
NodeTerm represents expressions and fields to transform node metadata.
Click to show internal directories.
Click to hide internal directories.