 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Overview ¶
Package driver contains the cloud provider specific implementations to manage machines
Package driver contains the cloud provider specific implementations to manage machines ¶
Package driver contains the cloud provider specific implementations to manage machines ¶
Package driver contains the cloud provider specific implementations to manage machines ¶
Package driver contains the cloud provider specific implementations to manage machines ¶
Package driver contains the cloud provider specific implementations to manage machines
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AWSDriver ¶
type AWSDriver struct {
	AWSMachineClass *v1alpha1.AWSMachineClass
	CloudConfig     *corev1.Secret
	UserData        string
	MachineID       string
	MachineName     string
}
    AWSDriver is the driver struct for holding AWS machine information
func (*AWSDriver) GetExisting ¶
GetExisting method is used to get machineID for existing AWS machine
type AzureDriver ¶
type AzureDriver struct {
	AzureMachineClass *v1alpha1.AzureMachineClass
	CloudConfig       *corev1.Secret
	UserData          string
	MachineID         string
	MachineName       string
}
    AzureDriver is the driver struct for holding azure machine information
func (*AzureDriver) Create ¶
func (d *AzureDriver) Create() (string, string, error)
Create method is used to create an azure machine
func (*AzureDriver) Delete ¶
func (d *AzureDriver) Delete() error
Delete method is used to delete an azure machine
func (*AzureDriver) GetExisting ¶
func (d *AzureDriver) GetExisting() (string, error)
GetExisting method is used to fetch the machineID for an azure machine
func (*AzureDriver) GetVMs ¶
func (d *AzureDriver) GetVMs(machineID string) (VMs, error)
GetVMs returns a list of VM or VM resources Azure earlier treated all VM resources (instance, NIC, Disks) as a single resource and atomically created/deleted them in the driver interface. This caused issues when the controller crashes, during deletions. To fix this, now GetVMs interface checks for all resources instead of just VMs.
type Driver ¶
type Driver interface {
	Create() (string, string, error)
	Delete() error
	GetExisting() (string, error)
	GetVMs(string) (VMs, error)
}
    Driver is the common interface for creation/deletion of the VMs over different cloud-providers.
func NewAWSDriver ¶
func NewAWSDriver(create func() (string, error), delete func() error, existing func() (string, error)) Driver
NewAWSDriver returns an empty AWSDriver object
type FakeDriver ¶
type FakeDriver struct {
	// contains filtered or unexported fields
}
    FakeDriver is a fake driver returned when none of the actual drivers match
func (*FakeDriver) Create ¶
func (d *FakeDriver) Create() (string, string, error)
Create returns a newly created fake driver
func (*FakeDriver) GetExisting ¶
func (d *FakeDriver) GetExisting() (string, error)
GetExisting returns the existing fake driver
type GCPDriver ¶
type GCPDriver struct {
	GCPMachineClass *v1alpha1.GCPMachineClass
	CloudConfig     *corev1.Secret
	UserData        string
	MachineID       string
	MachineName     string
}
    GCPDriver is the driver struct for holding GCP machine information
func (*GCPDriver) GetExisting ¶
GetExisting method is used to get machineID for existing GCP machine
type OpenStackDriver ¶
type OpenStackDriver struct {
	OpenStackMachineClass *v1alpha1.OpenStackMachineClass
	CloudConfig           *corev1.Secret
	UserData              string
	MachineID             string
	MachineName           string
}
    OpenStackDriver is the driver struct for holding OS machine information
func (*OpenStackDriver) Create ¶
func (d *OpenStackDriver) Create() (string, string, error)
Create method is used to create an OS machine
func (*OpenStackDriver) Delete ¶
func (d *OpenStackDriver) Delete() error
Delete method is used to delete an OS machine
func (*OpenStackDriver) GetExisting ¶
func (d *OpenStackDriver) GetExisting() (string, error)
GetExisting method is used to get machineID for existing OS machine