Documentation ¶
Index ¶
- Constants
- Variables
- type Command
- type DiskParams
- type IDeployer
- type IDisk
- type SKVMGuestDisk
- func (d *SKVMGuestDisk) Cleanup()
- func (d *SKVMGuestDisk) Connect() error
- func (d *SKVMGuestDisk) DetectIsUEFISupport(rootfs fsdriver.IRootFsDriver) bool
- func (d *SKVMGuestDisk) Disconnect() error
- func (d *SKVMGuestDisk) FormatPartition(fs, uuid string) error
- func (d *SKVMGuestDisk) IsLVMPartition() bool
- func (d *SKVMGuestDisk) MakePartition(fs string) error
- func (d *SKVMGuestDisk) MountKvmRootfs() (fsdriver.IRootFsDriver, error)
- func (d *SKVMGuestDisk) MountKvmRootfsReadOnly() (fsdriver.IRootFsDriver, error)
- func (d *SKVMGuestDisk) MountRootfs() (fsdriver.IRootFsDriver, error)
- func (d *SKVMGuestDisk) ResizePartition() error
- func (d *SKVMGuestDisk) UmountKvmRootfs(fd fsdriver.IRootFsDriver) error
- func (d *SKVMGuestDisk) UmountRootfs(fd fsdriver.IRootFsDriver) error
- func (d *SKVMGuestDisk) Zerofree()
- type VDDKDisk
- func (vd *VDDKDisk) Cleanup()
- func (vd *VDDKDisk) Connect() error
- func (vd *VDDKDisk) ConnectBlockDevice() (string, error)
- func (vd *VDDKDisk) Disconnect() error
- func (vd *VDDKDisk) DisconnectBlockDevice() error
- func (vd *VDDKDisk) ExecProg() error
- func (vd *VDDKDisk) Mount() (err error)
- func (vd *VDDKDisk) MountRootfs() (fsdriver.IRootFsDriver, error)
- func (vd *VDDKDisk) ParsePartitions(buf string) error
- func (vd *VDDKDisk) ResizePartition() error
- func (vd *VDDKDisk) Umount() error
- func (vd *VDDKDisk) UmountRootfs(fd fsdriver.IRootFsDriver) error
- func (vd *VDDKDisk) WaitMounted() error
- type VDDKPartition
- func (vp *VDDKPartition) GetPartDev() string
- func (vp *VDDKPartition) GetPhysicalPartitionType() string
- func (vp *VDDKPartition) IsMounted() bool
- func (vp *VDDKPartition) IsReadonly() bool
- func (vp *VDDKPartition) Mount() bool
- func (vp *VDDKPartition) MountPartReadOnly() bool
- func (vp *VDDKPartition) Umount() error
- func (vp *VDDKPartition) Zerofree()
Constants ¶
View Source
const (
TMPDIR = "/tmp/vmware-root"
)
Variables ¶
View Source
var (
MNT_PATTERN = regexp.MustCompile(`Disk flat file mounted under ([^\s]+)`)
)
Functions ¶
This section is empty.
Types ¶
type Command ¶
func NewCommand ¶
type DiskParams ¶
type DiskParams struct { Hypervisor string DiskInfo qemuimg.SImageInfo VddkInfo *apis.VDDKConInfo }
type IDisk ¶
type IDisk interface { Connect() error Disconnect() error MountRootfs() (fsdriver.IRootFsDriver, error) UmountRootfs(driver fsdriver.IRootFsDriver) error ResizePartition() error Cleanup() }
type SKVMGuestDisk ¶
type SKVMGuestDisk struct {
// contains filtered or unexported fields
}
func NewKVMGuestDisk ¶
func NewKVMGuestDisk(imageInfo qemuimg.SImageInfo, driver string, readOnly bool) (*SKVMGuestDisk, error)
func (*SKVMGuestDisk) Cleanup ¶
func (d *SKVMGuestDisk) Cleanup()
func (*SKVMGuestDisk) Connect ¶
func (d *SKVMGuestDisk) Connect() error
func (*SKVMGuestDisk) DetectIsUEFISupport ¶
func (d *SKVMGuestDisk) DetectIsUEFISupport(rootfs fsdriver.IRootFsDriver) bool
func (*SKVMGuestDisk) Disconnect ¶
func (d *SKVMGuestDisk) Disconnect() error
func (*SKVMGuestDisk) FormatPartition ¶
func (d *SKVMGuestDisk) FormatPartition(fs, uuid string) error
func (*SKVMGuestDisk) IsLVMPartition ¶
func (d *SKVMGuestDisk) IsLVMPartition() bool
func (*SKVMGuestDisk) MakePartition ¶
func (d *SKVMGuestDisk) MakePartition(fs string) error
func (*SKVMGuestDisk) MountKvmRootfs ¶
func (d *SKVMGuestDisk) MountKvmRootfs() (fsdriver.IRootFsDriver, error)
func (*SKVMGuestDisk) MountKvmRootfsReadOnly ¶
func (d *SKVMGuestDisk) MountKvmRootfsReadOnly() (fsdriver.IRootFsDriver, error)
func (*SKVMGuestDisk) MountRootfs ¶
func (d *SKVMGuestDisk) MountRootfs() (fsdriver.IRootFsDriver, error)
func (*SKVMGuestDisk) ResizePartition ¶
func (d *SKVMGuestDisk) ResizePartition() error
func (*SKVMGuestDisk) UmountKvmRootfs ¶
func (d *SKVMGuestDisk) UmountKvmRootfs(fd fsdriver.IRootFsDriver) error
func (*SKVMGuestDisk) UmountRootfs ¶
func (d *SKVMGuestDisk) UmountRootfs(fd fsdriver.IRootFsDriver) error
func (*SKVMGuestDisk) Zerofree ¶
func (d *SKVMGuestDisk) Zerofree()
type VDDKDisk ¶
type VDDKDisk struct { Host string Port int User string Passwd string VmRef string DiskPath string FUseDir string PartDirs []string Proc *Command Pid int // contains filtered or unexported fields }
func NewVDDKDisk ¶
func (*VDDKDisk) ConnectBlockDevice ¶
connect vddk disk as fuse block device on local host return fuse device path, is null error
func (*VDDKDisk) Disconnect ¶
func (*VDDKDisk) DisconnectBlockDevice ¶
func (*VDDKDisk) MountRootfs ¶
func (vd *VDDKDisk) MountRootfs() (fsdriver.IRootFsDriver, error)
func (*VDDKDisk) ParsePartitions ¶
func (*VDDKDisk) ResizePartition ¶
func (*VDDKDisk) UmountRootfs ¶
func (vd *VDDKDisk) UmountRootfs(fd fsdriver.IRootFsDriver) error
func (*VDDKDisk) WaitMounted ¶
type VDDKPartition ¶
type VDDKPartition struct {
*kvmpart.SLocalGuestFS
}
func (*VDDKPartition) GetPartDev ¶
func (vp *VDDKPartition) GetPartDev() string
func (*VDDKPartition) GetPhysicalPartitionType ¶
func (vp *VDDKPartition) GetPhysicalPartitionType() string
func (*VDDKPartition) IsMounted ¶
func (vp *VDDKPartition) IsMounted() bool
func (*VDDKPartition) IsReadonly ¶
func (vp *VDDKPartition) IsReadonly() bool
func (*VDDKPartition) Mount ¶
func (vp *VDDKPartition) Mount() bool
func (*VDDKPartition) MountPartReadOnly ¶
func (vp *VDDKPartition) MountPartReadOnly() bool
func (*VDDKPartition) Umount ¶
func (vp *VDDKPartition) Umount() error
func (*VDDKPartition) Zerofree ¶
func (vp *VDDKPartition) Zerofree()
Click to show internal directories.
Click to hide internal directories.