action

package
v0.0.0-...-eb548cc Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 6, 2015 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action interface {
}

type AttachDisk

type AttachDisk struct {
	// contains filtered or unexported fields
}

func NewAttachDisk

func NewAttachDisk(
	serverService server.Service,
	registryClient registry.Client,
) AttachDisk

func (AttachDisk) Run

func (ad AttachDisk) Run(vmCID VMCID, diskCID DiskCID) (interface{}, error)

type ConcreteFactory

type ConcreteFactory struct {
	// contains filtered or unexported fields
}

func NewConcreteFactory

func NewConcreteFactory(
	openstackClient client.OpenStackClient,
	uuidGen boshuuid.Generator,
	options ConcreteFactoryOptions,
	logger boshlog.Logger,
) ConcreteFactory

func (ConcreteFactory) Create

func (f ConcreteFactory) Create(method string) (Action, error)

type ConcreteFactoryOptions

type ConcreteFactoryOptions struct {
	Agent    registry.AgentOptions
	Registry registry.ClientOptions
}

func (ConcreteFactoryOptions) Validate

func (o ConcreteFactoryOptions) Validate() error

type ConfigureNetworks

type ConfigureNetworks struct {
	// contains filtered or unexported fields
}

func NewConfigureNetworks

func NewConfigureNetworks(
	serverService server.Service,
	registryClient registry.Client,
) ConfigureNetworks

func (ConfigureNetworks) Run

func (rv ConfigureNetworks) Run(vmCID VMCID, networks Networks) (interface{}, error)

type CreateDisk

type CreateDisk struct {
	// contains filtered or unexported fields
}

func NewCreateDisk

func NewCreateDisk(
	volumeService volume.Service,
	volumeTypeService volumetype.Service,
	serverService server.Service,
	ignoreServerAvailabilityZone bool,
) CreateDisk

func (CreateDisk) Run

func (cd CreateDisk) Run(size int, cloudProps DiskCloudProperties, vmCID VMCID) (DiskCID, error)

type CreateStemcell

type CreateStemcell struct {
	// contains filtered or unexported fields
}

func NewCreateStemcell

func NewCreateStemcell(
	imageService image.Service,
) CreateStemcell

func (CreateStemcell) Run

func (cs CreateStemcell) Run(stemcellPath string, cloudProps StemcellCloudProperties) (StemcellCID, error)

type CreateVM

type CreateVM struct {
	// contains filtered or unexported fields
}

func NewCreateVM

func NewCreateVM(
	serverService server.Service,
	flavorService flavor.Service,
	imageService image.Service,
	keypairService keypair.Service,
	volumeService volume.Service,
	registryClient registry.Client,
	registryOptions registry.ClientOptions,
	agentOptions registry.AgentOptions,
	defaultKeyPair string,
) CreateVM

func (CreateVM) Run

func (cv CreateVM) Run(agentID string, stemcellCID StemcellCID, cloudProps VMCloudProperties, networks Networks, disks []DiskCID, env Environment) (VMCID, error)

type DeleteDisk

type DeleteDisk struct {
	// contains filtered or unexported fields
}

func NewDeleteDisk

func NewDeleteDisk(
	volumeService volume.Service,
) DeleteDisk

func (DeleteDisk) Run

func (dd DeleteDisk) Run(diskCID DiskCID) (interface{}, error)

type DeleteSnapshot

type DeleteSnapshot struct {
	// contains filtered or unexported fields
}

func NewDeleteSnapshot

func NewDeleteSnapshot(
	snapshotService snapshot.Service,
) DeleteSnapshot

func (DeleteSnapshot) Run

func (ds DeleteSnapshot) Run(snapshotCID SnapshotCID) (interface{}, error)

type DeleteStemcell

type DeleteStemcell struct {
	// contains filtered or unexported fields
}

func NewDeleteStemcell

func NewDeleteStemcell(
	imageService image.Service,
) DeleteStemcell

func (DeleteStemcell) Run

func (ds DeleteStemcell) Run(stemcellCID StemcellCID) (interface{}, error)

type DeleteVM

type DeleteVM struct {
	// contains filtered or unexported fields
}

func NewDeleteVM

func NewDeleteVM(
	serverService server.Service,
	registryClient registry.Client,
) DeleteVM

func (DeleteVM) Run

func (dv DeleteVM) Run(vmCID VMCID) (interface{}, error)

type DetachDisk

type DetachDisk struct {
	// contains filtered or unexported fields
}

func NewDetachDisk

func NewDetachDisk(
	serverService server.Service,
	registryClient registry.Client,
) DetachDisk

func (DetachDisk) Run

func (dd DetachDisk) Run(vmCID VMCID, diskCID DiskCID) (interface{}, error)

type DiskCID

type DiskCID string

type DiskCloudProperties

type DiskCloudProperties struct {
	VolumeType       string `json:"volume_type,omitempty"`
	AvailabilityZone string `json:"availability_zone,omitempty"`
}

type Environment

type Environment map[string]interface{}

type Factory

type Factory interface {
	Create(method string) (Action, error)
}

type GetDisks

type GetDisks struct {
	// contains filtered or unexported fields
}

func NewGetDisks

func NewGetDisks(
	serverService server.Service,
) GetDisks

func (GetDisks) Run

func (gd GetDisks) Run(vmCID VMCID) (disks []string, err error)

type HasVM

type HasVM struct {
	// contains filtered or unexported fields
}

func NewHasVM

func NewHasVM(
	serverService server.Service,
) HasVM

func (HasVM) Run

func (hv HasVM) Run(vmCID VMCID) (bool, error)

type Network

type Network struct {
	Type            string                 `json:"type,omitempty"`
	IP              string                 `json:"ip,omitempty"`
	Gateway         string                 `json:"gateway,omitempty"`
	Netmask         string                 `json:"netmask,omitempty"`
	DNS             []string               `json:"dns,omitempty"`
	Default         []string               `json:"default,omitempty"`
	CloudProperties NetworkCloudProperties `json:"cloud_properties,omitempty"`
}

type NetworkCloudProperties

type NetworkCloudProperties struct {
	Network        string   `json:"network,omitempty"`
	SecurityGroups []string `json:"security_groups,omitempty"`
}

type Networks

type Networks map[string]Network

func (Networks) AsRegistryNetworks

func (ns Networks) AsRegistryNetworks() registry.NetworksSettings

func (Networks) AsServerServiceNetworks

func (ns Networks) AsServerServiceNetworks() server.Networks

type Ping

type Ping struct{}

func NewPing

func NewPing() Ping

func (Ping) Run

func (p Ping) Run() (string, error)

type RebootVM

type RebootVM struct {
	// contains filtered or unexported fields
}

func NewRebootVM

func NewRebootVM(
	serverService server.Service,
) RebootVM

func (RebootVM) Run

func (rv RebootVM) Run(vmCID VMCID) (interface{}, error)

type SetVMMetadata

type SetVMMetadata struct {
	// contains filtered or unexported fields
}

func NewSetVMMetadata

func NewSetVMMetadata(
	serverService server.Service,
) SetVMMetadata

func (SetVMMetadata) Run

func (svm SetVMMetadata) Run(vmCID VMCID, vmMetadata VMMetadata) (interface{}, error)

type SnapshotCID

type SnapshotCID string

type SnapshotDisk

type SnapshotDisk struct {
	// contains filtered or unexported fields
}

func NewSnapshotDisk

func NewSnapshotDisk(
	snapshotService snapshot.Service,
) SnapshotDisk

func (SnapshotDisk) Run

func (sd SnapshotDisk) Run(diskCID DiskCID, metadata SnapshotMetadata) (SnapshotCID, error)

type SnapshotMetadata

type SnapshotMetadata struct {
	Deployment string `json:"deployment,omitempty"`
	Job        string `json:"job,omitempty"`
	Index      string `json:"index,omitempty"`
}

type StemcellCID

type StemcellCID string

type StemcellCloudProperties

type StemcellCloudProperties struct {
	Name           string `json:"name,omitempty"`
	Version        string `json:"version,omitempty"`
	Infrastructure string `json:"infrastructure,omitempty"`
	ImageUUID      string `json:"image_uuid,omitempty"`
}

type VMCID

type VMCID string

type VMCloudProperties

type VMCloudProperties struct {
	Flavor           string                     `json:"flavor,omitempty"`
	AvailabilityZone string                     `json:"availability_zone,omitempty"`
	KeyPair          string                     `json:"keypair,omitempty"`
	RootDiskSizeGb   int                        `json:"root_disk_size_gb,omitempty"`
	SchedulerHints   VMSchedulerHintsProperties `json:"scheduler_hints,omitempty"`
}

type VMMetadata

type VMMetadata map[string]interface{}

type VMSchedulerHintsProperties

type VMSchedulerHintsProperties struct {
	Group           string        `json:"group,omitempty"`
	DifferentHost   []string      `json:"different_host,omitempty"`
	SameHost        []string      `json:"same_host,omitempty"`
	Query           []interface{} `json:"query,omitempty"`
	TargetCell      string        `json:"target_cell,omitempty"`
	BuildNearHostIP string        `json:"build_near_host_ip,omitempty"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL