Documentation ¶
Index ¶
- Constants
- func CreateEphemeralImages(vmi *v1.VirtualMachineInstance, ...) error
- func ExtractImageIDsFromSourcePod(vmi *v1.VirtualMachineInstance, sourcePod *kubev1.Pod) (imageIDs map[string]string, err error)
- func GenerateContainers(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, ...) []kubev1.Container
- func GenerateInitContainers(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, ...) []kubev1.Container
- func GenerateKernelBootContainer(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, ...) *kubev1.Container
- func GenerateKernelBootInitContainer(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, ...) *kubev1.Container
- func GetDiskTargetDirFromHostView(vmi *v1.VirtualMachineInstance) (*safepath.Path, error)
- func GetDiskTargetName(volumeIndex int) string
- func GetDiskTargetPartFromLauncherView(volumeIndex int) (string, error)
- func GetDiskTargetPathFromLauncherView(volumeIndex int) string
- func GetImage(root *safepath.Path, imagePath string) (*safepath.Path, error)
- func GetKernelBootArtifactPathFromLauncherView(artifact string) string
- func GetLegacyVolumeMountDirOnHost(vmi *v1.VirtualMachineInstance) string
- func GetVolumeMountDirOnGuest(vmi *v1.VirtualMachineInstance) string
- func GetVolumeMountDirOnHost(vmi *v1.VirtualMachineInstance) (*safepath.Path, error)
- func SetKubeletPodsDirectory(dir string)
- func SetLocalDirectory(dir string) error
- func VerifyImage(diskInfo *DiskInfo) error
- func VerifyQCOW2(diskInfo *DiskInfo) error
- type DiskInfo
- type KernelBootSocketPathGetter
- type SocketPathGetter
Constants ¶
View Source
const (
DiskSourceFallbackPath = "/disk"
)
View Source
const KernelBootName = "kernel-boot"
View Source
const KernelBootVolumeName = KernelBootName + "-volume"
Variables ¶
This section is empty.
Functions ¶
func CreateEphemeralImages ¶ added in v0.20.0
func CreateEphemeralImages( vmi *v1.VirtualMachineInstance, diskCreator ephemeraldisk.EphemeralDiskCreatorInterface, disksInfo map[string]*DiskInfo, ) error
func ExtractImageIDsFromSourcePod ¶ added in v0.47.0
func ExtractImageIDsFromSourcePod(vmi *v1.VirtualMachineInstance, sourcePod *kubev1.Pod) (imageIDs map[string]string, err error)
ExtractImageIDsFromSourcePod takes the VMI and its source pod to determine the exact image used by containerdisks and boot container images, which is recorded in the status section of a started pod. It returns a map where the key is the vlume name and the value is the imageID
func GenerateContainers ¶
func GenerateContainers(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, imageIDs map[string]string, podVolumeName string, binVolumeName string) []kubev1.Container
func GenerateInitContainers ¶ added in v0.34.0
func GenerateInitContainers(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, imageIDs map[string]string, podVolumeName string, binVolumeName string) []kubev1.Container
func GenerateKernelBootContainer ¶ added in v0.42.0
func GenerateKernelBootContainer(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, imageIDs map[string]string, podVolumeName string, binVolumeName string) *kubev1.Container
func GenerateKernelBootInitContainer ¶ added in v0.47.0
func GenerateKernelBootInitContainer(vmi *v1.VirtualMachineInstance, config *virtconfig.ClusterConfig, imageIDs map[string]string, podVolumeName string, binVolumeName string) *kubev1.Container
func GetDiskTargetDirFromHostView ¶ added in v0.42.0
func GetDiskTargetDirFromHostView(vmi *v1.VirtualMachineInstance) (*safepath.Path, error)
func GetDiskTargetName ¶ added in v0.49.1
func GetDiskTargetPartFromLauncherView ¶ added in v0.20.0
GetDiskTargetPartFromLauncherView returns (path to disk image, image type, and error)
func GetDiskTargetPathFromLauncherView ¶ added in v0.29.0
func GetKernelBootArtifactPathFromLauncherView ¶ added in v0.42.0
func GetLegacyVolumeMountDirOnHost ¶ added in v0.29.0
func GetLegacyVolumeMountDirOnHost(vmi *v1.VirtualMachineInstance) string
func GetVolumeMountDirOnGuest ¶ added in v0.29.0
func GetVolumeMountDirOnGuest(vmi *v1.VirtualMachineInstance) string
func GetVolumeMountDirOnHost ¶ added in v0.29.0
func GetVolumeMountDirOnHost(vmi *v1.VirtualMachineInstance) (*safepath.Path, error)
func SetKubeletPodsDirectory ¶ added in v0.30.0
func SetKubeletPodsDirectory(dir string)
func SetLocalDirectory ¶
func VerifyImage ¶ added in v0.20.0
func VerifyQCOW2 ¶ added in v0.20.0
Types ¶
type KernelBootSocketPathGetter ¶ added in v0.42.0
type KernelBootSocketPathGetter func(vmi *v1.VirtualMachineInstance) (string, error)
func NewKernelBootSocketPathGetter ¶ added in v0.42.0
func NewKernelBootSocketPathGetter(baseDir string) KernelBootSocketPathGetter
NewKernelBootSocketPathGetter get the socket pat of the kernel-boot containerDisk. For testing a baseDir can be provided which can for instance point to /tmp.
type SocketPathGetter ¶ added in v0.30.6
type SocketPathGetter func(vmi *v1.VirtualMachineInstance, volumeIndex int) (string, error)
func NewSocketPathGetter ¶ added in v0.30.6
func NewSocketPathGetter(baseDir string) SocketPathGetter
NewSocketPathGetter get the socket pat of a containerDisk. For testing a baseDir can be provided which can for instance point to /tmp.
Click to show internal directories.
Click to hide internal directories.