Documentation
¶
Index ¶
Constants ¶
View Source
const ( // NormalizedInterfacePrefix is prefix used when normalizing a network // interface. NormalizedInterfacePrefix = "net" // NormalizedPCIPrefix is the prefix used when normalizing a PCI Address. NormalizedPCIPrefix = "pci" )
Variables ¶
This section is empty.
Functions ¶
func NormalizeInterfaceName ¶ added in v0.7.0
NormalizeInterfaceName determines the appropriate name for an interface in Kubernetes. If the original interface name (ifName) is already a valid DNS-1123 label, it's returned as is. Otherwise, it's encoded using Base32, prefixed with NormalizedPrefix, and returned.
Linux interface names (often limited by IFNAMSIZ, typically 16) plus the base32 encoding and the normalized prefix (11) are within the DNS-1123 label, which has a maximum length of 63.
func NormalizePCIAddress ¶ added in v0.7.0
NormalizePCIAddress takes a PCI address and converts it into a DNS-1123 acceptable format.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.