Documentation
¶
Index ¶
- Constants
- func ForceKillVirtLauncherAtNode(p infraapi.Provider, nodeName, vmNamespace, vmName string) error
- func GenerateAddressDiscoveryConfigurationCommand(iface string) string
- func GenerateAddressesAnnotations(networkName string, addresses []string) (map[string]string, error)
- func GenerateCUDN(namespace, name string, topology udnv1.NetworkTopology, role udnv1.NetworkRole, ...) (*udnv1.ClusterUserDefinedNetwork, string)
- func GenerateFakeVirtLauncherPod(namespace, vmName string) *corev1.Pod
- func GenerateGatewayIPv6RouterLLA(subnets []string) (string, error)
- func GenerateGatewayMAC(subnets []string) (string, error)
- func GetLayer2UDNDefaultGWIPs(subnets []string) ([]*net.IP, error)
- func RetrieveAllGlobalAddressesFromGuest(cli *Client, vmi *v1.VirtualMachineInstance) ([]string, error)
- func RetrieveCachedGatewayMAC(cli *Client, vmi *kubevirtv1.VirtualMachineInstance, dev, cidr string) (string, error)
- func RetrieveIPv6Gateways(cli *Client, vmi *v1.VirtualMachineInstance) ([]string, error)
- type Address
- type Client
- func (virtctl *Client) LoginToFedora(vmi *kubevirtv1.VirtualMachineInstance, user, password string) error
- func (virtctl *Client) RestartVirtualMachine(vmi *kubevirtv1.VirtualMachineInstance) (string, error)
- func (virtctl *Client) RunCommand(vmi *v1.VirtualMachineInstance, command string, timeout time.Duration) (string, error)
- type IP
- type Interface
- type NetworkState
Constants ¶
View Source
const ( PromptExpression = `(\$ |\# )` CRLF = "\r\n" UTFPosEscape = "\u001b\\[[0-9]+;[0-9]+H" )
View Source
const ( FedoraCoreOSContainerDiskImage = "quay.io/kubevirtci/fedora-coreos-kubevirt:v20230905-be4fa50" FedoraWithTestToolingContainerDiskImage = "quay.io/kubevirtci/fedora-with-test-tooling:v20250416-e37573e" FedoraContainerDiskImage = "quay.io/containerdisks/fedora:39" FakeLauncherImage = "quay.io/nmstate/c10s-nmstate-dev:latest" )
View Source
const (
AddressesAnnotation = "network.kubevirt.io/addresses"
)
Variables ¶
This section is empty.
Functions ¶
func GenerateCUDN ¶
func GenerateCUDN(namespace, name string, topology udnv1.NetworkTopology, role udnv1.NetworkRole, subnets udnv1.DualStackCIDRs) (*udnv1.ClusterUserDefinedNetwork, string)
GenerateCUDN creates a new ClusterUserDefinedNetwork (CUDN) object with the specified parameters. Parameters: - namespace: The namespace in which the CUDN will be created. - name: The name of the CUDN. - topology: The network topology for the CUDN. - role: The network role for the CUDN. - subnets: The dual-stack CIDRs for the CUDN. Returns: - A pointer to the created ClusterUserDefinedNetwork object. - A string representation of the CUDN's network name.
func GenerateGatewayMAC ¶
func GetLayer2UDNDefaultGWIPs ¶
GetLayer2UDNDefaultGWIPs returns the default gateway IPs (.1) for a Layer2 UDN subnet
func RetrieveAllGlobalAddressesFromGuest ¶
func RetrieveAllGlobalAddressesFromGuest(cli *Client, vmi *v1.VirtualMachineInstance) ([]string, error)
func RetrieveCachedGatewayMAC ¶
func RetrieveCachedGatewayMAC(cli *Client, vmi *kubevirtv1.VirtualMachineInstance, dev, cidr string) (string, error)
func RetrieveIPv6Gateways ¶
func RetrieveIPv6Gateways(cli *Client, vmi *v1.VirtualMachineInstance) ([]string, error)
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) LoginToFedora ¶
func (virtctl *Client) LoginToFedora(vmi *kubevirtv1.VirtualMachineInstance, user, password string) error
func (*Client) RestartVirtualMachine ¶
func (virtctl *Client) RestartVirtualMachine(vmi *kubevirtv1.VirtualMachineInstance) (string, error)
func (*Client) RunCommand ¶
type NetworkState ¶
type NetworkState struct {
Interfaces []Interface `json:"interfaces"`
}
func RetrieveNetworkState ¶
func RetrieveNetworkState(cli *Client, vmi *v1.VirtualMachineInstance) (*NetworkState, error)
Click to show internal directories.
Click to hide internal directories.