Documentation
¶
Index ¶
- Variables
- func GetVMCachePath(imageId string, user user.User) (longID string, path string, err error)
- func StartMonitor(ctx context.Context, params MonitorParmeters) error
- type BootcVM
- type BootcVMCommon
- func (v *BootcVMCommon) CacheDir() string
- func (v *BootcVMCommon) DeleteFromCache() error
- func (v *BootcVMCommon) LoadConfigFile() (cfg *BootcVMConfig, err error)
- func (b *BootcVMCommon) ParseCloudInit() (err error)
- func (v *BootcVMCommon) RunSSH(inputArgs []string) error
- func (v *BootcVMCommon) SetUser(user string) error
- func (v *BootcVMCommon) WaitForSSHToBeReady() error
- func (v *BootcVMCommon) WriteConfig(bootcDisk bootc.BootcDisk) error
- type BootcVMConfig
- type BootcVMLinux
- func (v *BootcVMLinux) CloseConnection()
- func (v *BootcVMLinux) Delete() (err error)
- func (v *BootcVMLinux) Exists() (bool, error)
- func (v *BootcVMLinux) GetConfig() (cfg *BootcVMConfig, err error)
- func (v *BootcVMLinux) IsRunning() (exists bool, err error)
- func (v *BootcVMLinux) PrintConsole() (err error)
- func (v *BootcVMLinux) Run(params RunVMParameters) (err error)
- func (v *BootcVMLinux) Shutdown() (err error)
- func (v *BootcVMLinux) Unlock() error
- type MonitorParmeters
- type NewVMParameters
- type RunVMParameters
- type Vmm
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrVMInUse = errors.New("VM already in use")
Functions ¶
func GetVMCachePath ¶
GetVMCachePath returns the path to the VM cache directory
func StartMonitor ¶
func StartMonitor(ctx context.Context, params MonitorParmeters) error
Types ¶
type BootcVM ¶
type BootcVM interface { Run(RunVMParameters) error Delete() error IsRunning() (bool, error) WriteConfig(bootc.BootcDisk) error WaitForSSHToBeReady() error RunSSH([]string) error DeleteFromCache() error CacheDir() string Exists() (bool, error) GetConfig() (*BootcVMConfig, error) CloseConnection() PrintConsole() error Unlock() error }
type BootcVMCommon ¶
type BootcVMCommon struct {
// contains filtered or unexported fields
}
func (*BootcVMCommon) CacheDir ¶
func (v *BootcVMCommon) CacheDir() string
func (*BootcVMCommon) DeleteFromCache ¶
func (v *BootcVMCommon) DeleteFromCache() error
Delete removes the VM disk image and the VM configuration from the podman-bootc cache
func (*BootcVMCommon) LoadConfigFile ¶
func (v *BootcVMCommon) LoadConfigFile() (cfg *BootcVMConfig, err error)
func (*BootcVMCommon) ParseCloudInit ¶
func (b *BootcVMCommon) ParseCloudInit() (err error)
func (*BootcVMCommon) RunSSH ¶
func (v *BootcVMCommon) RunSSH(inputArgs []string) error
RunSSH runs a command over ssh or starts an interactive ssh connection if no command is provided
func (*BootcVMCommon) SetUser ¶
func (v *BootcVMCommon) SetUser(user string) error
func (*BootcVMCommon) WaitForSSHToBeReady ¶
func (v *BootcVMCommon) WaitForSSHToBeReady() error
func (*BootcVMCommon) WriteConfig ¶
func (v *BootcVMCommon) WriteConfig(bootcDisk bootc.BootcDisk) error
writeConfig writes the configuration for the VM to the disk
type BootcVMConfig ¶
type BootcVMLinux ¶
type BootcVMLinux struct { BootcVMCommon // contains filtered or unexported fields }
func NewVM ¶
func NewVM(params NewVMParameters) (vm *BootcVMLinux, err error)
func (*BootcVMLinux) CloseConnection ¶
func (v *BootcVMLinux) CloseConnection()
func (*BootcVMLinux) Exists ¶
func (v *BootcVMLinux) Exists() (bool, error)
func (*BootcVMLinux) GetConfig ¶
func (v *BootcVMLinux) GetConfig() (cfg *BootcVMConfig, err error)
func (*BootcVMLinux) IsRunning ¶
func (v *BootcVMLinux) IsRunning() (exists bool, err error)
func (*BootcVMLinux) PrintConsole ¶
func (v *BootcVMLinux) PrintConsole() (err error)
func (*BootcVMLinux) Run ¶
func (v *BootcVMLinux) Run(params RunVMParameters) (err error)
func (*BootcVMLinux) Unlock ¶
func (v *BootcVMLinux) Unlock() error
type MonitorParmeters ¶
type NewVMParameters ¶
type RunVMParameters ¶
Click to show internal directories.
Click to hide internal directories.