Documentation ¶
Index ¶
- Constants
- type Image
- type ImageListResponse
- type Instance
- type InstancesListResponse
- type Objects
- type Relayered
- func (v *Relayered) AttachVolume(ctx *lepton.Context, image, name string, attachID int) error
- func (v *Relayered) BuildImage(ctx *lepton.Context) (string, error)
- func (v *Relayered) BuildImageWithPackage(ctx *lepton.Context, pkgpath string) (string, error)
- func (v *Relayered) CreateImage(ctx *lepton.Context, imagePath string) error
- func (v *Relayered) CreateInstance(ctx *lepton.Context) error
- func (v *Relayered) CreateVolume(ctx *lepton.Context, cv types.CloudVolume, data string, provider string) (lepton.NanosVolume, error)
- func (v *Relayered) CustomizeImage(ctx *lepton.Context) (string, error)
- func (v *Relayered) DeleteImage(ctx *lepton.Context, snapshotID string) error
- func (v *Relayered) DeleteInstance(ctx *lepton.Context, instanceID string) error
- func (v *Relayered) DeleteVolume(ctx *lepton.Context, name string) error
- func (v *Relayered) DetachVolume(ctx *lepton.Context, image, name string) error
- func (v *Relayered) GetAllVolumes(ctx *lepton.Context) (*[]lepton.NanosVolume, error)
- func (v *Relayered) GetImages(ctx *lepton.Context, filter string) ([]lepton.CloudImage, error)
- func (v *Relayered) GetInstanceByName(ctx *lepton.Context, name string) (*lepton.CloudInstance, error)
- func (v *Relayered) GetInstanceLogs(ctx *lepton.Context, instancename string) (string, error)
- func (v *Relayered) GetInstances(ctx *lepton.Context) ([]lepton.CloudInstance, error)
- func (v *Relayered) GetStorage() lepton.Storage
- func (v *Relayered) Initialize(config *types.ProviderConfig) error
- func (v *Relayered) InstanceStats(ctx *lepton.Context, instancename string, watch bool) error
- func (v *Relayered) ListImages(ctx *lepton.Context, filter string) error
- func (v *Relayered) ListInstances(ctx *lepton.Context) error
- func (v *Relayered) PrintInstanceLogs(ctx *lepton.Context, instancename string, watch bool) error
- func (v *Relayered) RebootInstance(ctx *lepton.Context, instanceName string) error
- func (v *Relayered) ResizeImage(ctx *lepton.Context, imagename string, hbytes string) error
- func (v *Relayered) StartInstance(ctx *lepton.Context, instanceID string) error
- func (v *Relayered) StopInstance(ctx *lepton.Context, instanceID string) error
- func (v *Relayered) SyncImage(config *types.Config, target lepton.Provider, image string) error
- type ResourceGroup
- type ResourceGroupResponse
- type Subnet
- type SubnetListResponse
- type SubnetResponse
- type VPC
- type VPCListResponse
Constants ¶
const ProviderName = "relayered"
ProviderName of the cloud platform provider
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Image ¶
type Image struct { ID string `json:"id"` Name string `json:"name"` Status string `json:"status"` CreatedAt string `json:"created_at"` }
Image represents a given relayered image configuration.
type ImageListResponse ¶
type ImageListResponse []Image
ImageListResponse is the set of instances available from relayered in an images list call.
type Instance ¶
type Instance struct { ID string `json:"id"` Name string `json:"name"` Image string `json:"image"` Created string `json:"created"` Status string `json:"status"` CreatedAt string `json:"created_at"` }
Instance represents a virtual server instance.
type InstancesListResponse ¶
type InstancesListResponse []Instance
InstancesListResponse is the set of instances available from relayered in an images list call.
type Objects ¶
type Objects struct {
// contains filtered or unexported fields
}
Objects represent storage specific information for cloud object storage.
func (*Objects) CopyToBucket ¶
CopyToBucket copies archive to bucket
type Relayered ¶
type Relayered struct { Storage *Objects // contains filtered or unexported fields }
Relayered Provider to interact with relayered infrastructure
func (*Relayered) AttachVolume ¶
AttachVolume is a stub to satisfy VolumeService interface
func (*Relayered) BuildImage ¶
BuildImage to be upload on relayered
func (*Relayered) BuildImageWithPackage ¶
BuildImageWithPackage to upload on relayered.
func (*Relayered) CreateImage ¶
CreateImage - Creates image on relayered using nanos images
func (*Relayered) CreateInstance ¶
CreateInstance - Creates instance on relayered Cloud Platform
func (*Relayered) CreateVolume ¶
func (v *Relayered) CreateVolume(ctx *lepton.Context, cv types.CloudVolume, data string, provider string) (lepton.NanosVolume, error)
CreateVolume is a stub to satisfy VolumeService interface
func (*Relayered) CustomizeImage ¶
CustomizeImage returns image path with adaptations needed by cloud provider
func (*Relayered) DeleteImage ¶
DeleteImage deletes image from v
func (*Relayered) DeleteInstance ¶
DeleteInstance deletes instance from relayered
func (*Relayered) DeleteVolume ¶
DeleteVolume is a stub to satisfy VolumeService interface
func (*Relayered) DetachVolume ¶
DetachVolume is a stub to satisfy VolumeService interface
func (*Relayered) GetAllVolumes ¶
GetAllVolumes is a stub to satisfy VolumeService interface
func (*Relayered) GetInstanceByName ¶
func (v *Relayered) GetInstanceByName(ctx *lepton.Context, name string) (*lepton.CloudInstance, error)
GetInstanceByName returns instance with given name
func (*Relayered) GetInstanceLogs ¶
GetInstanceLogs gets instance related logs
func (*Relayered) GetInstances ¶
GetInstances return all instances on relayered
func (*Relayered) GetStorage ¶
GetStorage returns storage interface for cloud provider
func (*Relayered) Initialize ¶
func (v *Relayered) Initialize(config *types.ProviderConfig) error
Initialize provider
func (*Relayered) InstanceStats ¶
InstanceStats show metrics for instances on relayered
func (*Relayered) ListImages ¶
ListImages lists images on relayered
func (*Relayered) ListInstances ¶
ListInstances lists instances on v
func (*Relayered) PrintInstanceLogs ¶
PrintInstanceLogs writes instance logs to console
func (*Relayered) RebootInstance ¶
RebootInstance reboots the instance.
func (*Relayered) ResizeImage ¶
ResizeImage is not supported on relayered.
func (*Relayered) StartInstance ¶
StartInstance starts an instance in relayered
func (*Relayered) StopInstance ¶
StopInstance halts instance from v
type ResourceGroup ¶
ResourceGroup represents a single resource group.
type ResourceGroupResponse ¶
type ResourceGroupResponse struct {
ResourceGroups []ResourceGroup `json:"resources"`
}
ResourceGroupResponse is the response type for the resource group list endpoint.
type SubnetListResponse ¶
type SubnetListResponse struct {
Subnets []Subnet `json:"subnets"`
}
SubnetListResponse is the response type for the subnet list endpoint.
type SubnetResponse ¶
type SubnetResponse struct {
Subnets []Subnet `json:"subnets"`
}
SubnetResponse is the response type for the subnet list endpoint.
type VPCListResponse ¶
type VPCListResponse struct {
VPCs []VPC `json:"vpcs"`
}
VPCListResponse is the response type for the vpc list endpoint.