Documentation ¶
Index ¶
- Constants
- func AddIPAddress(vmi *v1.VirtualMachineInstance, interfaceName, interfaceAddress string) error
- func AddLabelToNamespace(client kubecli.KubevirtClient, namespace, key, value string) error
- func CidrToIP(cidr string) (string, error)
- func CreateMacvtapNetworkAttachmentDefinition(namespace, networkName, macvtapLowerDevice string) error
- func CreateNAD(namespace, nadName string) error
- func CreateNetworkAttachmentDefinition(name, namespace, netConf string) error
- func CreatePasstNetworkAttachmentDefinition(namespace string) error
- func FormatIPForURL(ip string) string
- func GetIP(ips []string, family k8sv1.IPFamily) string
- func GetLoopbackAddress(family k8sv1.IPFamily) string
- func GetLoopbackAddressForURL(family k8sv1.IPFamily) string
- func GetPodIPByFamily(pod *k8sv1.Pod, family k8sv1.IPFamily) string
- func GetVmiPrimaryIPByFamily(vmi *v1.VirtualMachineInstance, family k8sv1.IPFamily) string
- func InterfaceExists(vmi *v1.VirtualMachineInstance, interfaceName string) error
- func LookupNetworkByName(networks []v1.Network, name string) *v1.Network
- func NewExposeArgs(resource, namespace, name string, opts ...Option) []string
- func NewVMExposeArgs(vm *v1.VirtualMachine, opts ...Option) []string
- func NewVMIExposeArgs(vmi *v1.VirtualMachineInstance, opts ...Option) []string
- func NewVMIRSExposeArgs(vmrs *v1.VirtualMachineInstanceReplicaSet, opts ...Option) []string
- func PatchNamespace(client kubecli.KubevirtClient, namespace string, patchFunc func(*v1.Namespace)) error
- func PingFromVMConsole(vmi *v1.VirtualMachineInstance, ipAddr string, args ...string) error
- func RemoveLabelFromNamespace(client kubecli.KubevirtClient, namespace, key string) error
- func SetInterfaceUp(vmi *v1.VirtualMachineInstance, interfaceName string) error
- func SkipWhenClusterNotSupportIPFamily(ipFamily k8sv1.IPFamily)
- func SkipWhenClusterNotSupportIpv4()
- func SkipWhenClusterNotSupportIpv6()
- func ValidateVMIandPodIPMatch(vmi *v1.VirtualMachineInstance, vmiPod *k8sv1.Pod) error
- func WithMasqueradeNetworking(ports ...v1.Port) []libvmi.Option
- func WithPort(port string) func(cmdArgs []string) []string
- func WithProtocol(protocol string) func(cmdArgs []string) []string
- func WithServiceName(serviceName string) func(cmdArgs []string) []string
- func WithTargetPort(targetPort string) func(cmdArgs []string) []string
- func WithType(serviceType string) func(cmdArgs []string) []string
- type Option
Constants ¶
View Source
const PasstNetAttDef = "netbindingpasst"
Variables ¶
This section is empty.
Functions ¶
func AddIPAddress ¶ added in v1.2.0
func AddIPAddress(vmi *v1.VirtualMachineInstance, interfaceName, interfaceAddress string) error
func AddLabelToNamespace ¶ added in v0.42.0
func AddLabelToNamespace(client kubecli.KubevirtClient, namespace, key, value string) error
func CreateMacvtapNetworkAttachmentDefinition ¶ added in v1.2.0
func CreateNetworkAttachmentDefinition ¶ added in v1.2.0
func CreatePasstNetworkAttachmentDefinition ¶ added in v1.2.0
func FormatIPForURL ¶ added in v1.1.0
func GetLoopbackAddress ¶ added in v0.52.0
func GetLoopbackAddressForURL ¶ added in v0.55.0
func GetPodIPByFamily ¶ added in v0.55.0
func GetVmiPrimaryIPByFamily ¶ added in v0.55.0
func GetVmiPrimaryIPByFamily(vmi *v1.VirtualMachineInstance, family k8sv1.IPFamily) string
func InterfaceExists ¶ added in v1.0.0
func InterfaceExists(vmi *v1.VirtualMachineInstance, interfaceName string) error
func LookupNetworkByName ¶ added in v1.0.1
func NewExposeArgs ¶ added in v0.45.0
func NewVMExposeArgs ¶ added in v0.45.0
func NewVMExposeArgs(vm *v1.VirtualMachine, opts ...Option) []string
func NewVMIExposeArgs ¶ added in v0.45.0
func NewVMIExposeArgs(vmi *v1.VirtualMachineInstance, opts ...Option) []string
func NewVMIRSExposeArgs ¶ added in v0.45.0
func NewVMIRSExposeArgs(vmrs *v1.VirtualMachineInstanceReplicaSet, opts ...Option) []string
func PatchNamespace ¶ added in v0.58.1
func PingFromVMConsole ¶ added in v0.35.0
func PingFromVMConsole(vmi *v1.VirtualMachineInstance, ipAddr string, args ...string) error
PingFromVMConsole performs a ping through the provided VMI console. Optional arguments for the ping command may be provided, overwirting the default ones. (default ping options: "-c 5, -w 10") Note: The maximum overall command timeout is 20 seconds.
func RemoveLabelFromNamespace ¶ added in v0.42.0
func RemoveLabelFromNamespace(client kubecli.KubevirtClient, namespace, key string) error
func SetInterfaceUp ¶ added in v1.2.0
func SetInterfaceUp(vmi *v1.VirtualMachineInstance, interfaceName string) error
func SkipWhenClusterNotSupportIPFamily ¶ added in v0.55.0
func SkipWhenClusterNotSupportIpv4 ¶ added in v0.52.0
func SkipWhenClusterNotSupportIpv4()
func SkipWhenClusterNotSupportIpv6 ¶ added in v0.52.0
func SkipWhenClusterNotSupportIpv6()
func ValidateVMIandPodIPMatch ¶ added in v0.35.0
func ValidateVMIandPodIPMatch(vmi *v1.VirtualMachineInstance, vmiPod *k8sv1.Pod) error
ValidateVMIandPodIPMatch Checks that the vmi pod and vmi scheme have matching Ip/Ips fields for primary interface
func WithMasqueradeNetworking ¶ added in v1.3.0
func WithProtocol ¶ added in v0.45.0
func WithServiceName ¶ added in v0.45.0
func WithTargetPort ¶ added in v0.45.0
Types ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.