resources

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2017 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SpectrumScale    string = "spectrum-scale"
	SpectrumScaleNFS string = "spectrum-scale-nfs"
	SoftlayerNFS     string = "softlayer-nfs"
	SCBE             string = "scbe"
	LocalHost        string = "localhost"
)
View Source
const DefaultForScbeConfigParamDefaultFilesystem = "ext4" // if customer don't mention fstype, then the default is ext4
View Source
const DefaultForScbeConfigParamDefaultVolumeSize = "1" // if customer don't mention size, then the default is 1gb
View Source
const OptionNameForVolumeFsType = "fstype" // the option name of the fstype and also the key in the volumeConfig
View Source
const PathToMountUbiquityBlockDevices = "/ubiquity/%s" // %s is the WWN of the volume # TODO this should be moved to docker plugin side
View Source
const UbiquityInstanceNameMaxSize = 15

Variables

This section is empty.

Functions

This section is empty.

Types

type ActivateRequest

type ActivateRequest struct {
	Backends []string
	Opts     map[string]string
}

type ActivateResponse

type ActivateResponse struct {
	Error error
}

type AfterDetachRequest

type AfterDetachRequest struct {
	VolumeConfig map[string]interface{}
}

type AfterDetachResponse added in v0.4.1

type AfterDetachResponse struct {
	Error error
}

type AttachRequest

type AttachRequest struct {
	Name string
	Host string
}

type AttachResponse

type AttachResponse struct {
	Mountpoint string
	Error      error
}

type BrokerConfig

type BrokerConfig struct {
	ConfigPath string
	Port       int //for CF Service broker
}

type ConnectionInfo

type ConnectionInfo struct {
	CredentialInfo CredentialInfo
	Port           int
	ManagementIP   string
	SkipVerifySSL  bool
}

type CreateVolumeRequest

type CreateVolumeRequest struct {
	Name          string
	Backend       string
	CapacityBytes uint64
	Metadata      map[string]string
}

type CreateVolumeResponse added in v0.4.1

type CreateVolumeResponse struct {
	Volume Volume
	Error  error
}

type CredentialInfo

type CredentialInfo struct {
	UserName string `json:"username"`
	Password string `json:"password"`
	Group    string `json:"group"`
}

type DetachRequest

type DetachRequest struct {
	Name string
	Host string
}

type DetachResponse added in v0.4.1

type DetachResponse struct {
	Error error
}

type DockerGetResponse

type DockerGetResponse struct {
	Volume map[string]interface{}
	Err    string
}

type GenericRequest

type GenericRequest struct {
	Name string
}

type GenericResponse

type GenericResponse struct {
	Err string
}

type GetConfigResponse

type GetConfigResponse struct {
	VolumeConfig map[string]interface{}
	Err          string
}

type GetVolumeConfigRequest

type GetVolumeConfigRequest struct {
	Name string
}

type GetVolumeConfigResponse added in v0.4.1

type GetVolumeConfigResponse struct {
	VolumeConfig map[string]interface{}
	Error        error
}

type GetVolumeRequest

type GetVolumeRequest struct {
	Name string
}

type GetVolumeResponse added in v0.4.1

type GetVolumeResponse struct {
	Volume Volume
	Error  error
}

type ListResponse

type ListResponse struct {
	Volumes []Volume
	Err     string
}

type ListVolumesRequest

type ListVolumesRequest struct {
	//TODO add filter
	Backends []string
}

type ListVolumesResponse added in v0.4.1

type ListVolumesResponse struct {
	Volumes []Volume
	Error   error
}

type LocalHostConfig added in v0.4.1

type LocalHostConfig struct {
	LocalhostPath string
}

type MountRequest

type MountRequest struct {
	Mountpoint   string
	VolumeConfig map[string]interface{}
}

type MountResponse

type MountResponse struct {
	Mountpoint string
	Error      error
}

type Mounter

type Mounter interface {
	Mount(mountRequest MountRequest) MountResponse
	Unmount(unmountRequest UnmountRequest) UnmountResponse
	ActionAfterDetach(request AfterDetachRequest) AfterDetachResponse
}

type RemoveVolumeRequest

type RemoveVolumeRequest struct {
	Name string
}

type RemoveVolumeResponse added in v0.4.1

type RemoveVolumeResponse struct {
	Error error
}

type RestConfig

type RestConfig struct {
	Endpoint string
	User     string
	Password string
	Hostname string
}

type ScbeConfig

type ScbeConfig struct {
	ConfigPath           string // TODO consider to remove later
	ConnectionInfo       ConnectionInfo
	DefaultService       string // SCBE storage service to be used by default if not mentioned by plugin
	DefaultVolumeSize    string // The default volume size in case not specified by user
	UbiquityInstanceName string // Prefix for the volume name in the storage side (max length 15 char)

	DefaultFilesystemType string // The default filesystem type to create on new provisioned volume during attachment to the host
}

type ScbeRemoteConfig added in v0.4.0

type ScbeRemoteConfig struct {
	SkipRescanISCSI bool
}

type SpectrumNfsRemoteConfig

type SpectrumNfsRemoteConfig struct {
	ClientConfig string
}

type SpectrumScaleConfig

type SpectrumScaleConfig struct {
	DefaultFilesystemName string
	NfsServerAddr         string
	SshConfig             SshConfig
	RestConfig            RestConfig
	ForceDelete           bool
}

TODO we should consider to move dedicated backend structs to the backend resource file instead of this one.

type SshConfig

type SshConfig struct {
	User string
	Host string
	Port string
}

type StorageClient

type StorageClient interface {
	Activate(activateRequest ActivateRequest) ActivateResponse
	CreateVolume(createVolumeRequest CreateVolumeRequest) CreateVolumeResponse
	RemoveVolume(removeVolumeRequest RemoveVolumeRequest) RemoveVolumeResponse
	ListVolumes(listVolumeRequest ListVolumesRequest) ListVolumesResponse
	GetVolume(getVolumeRequest GetVolumeRequest) GetVolumeResponse
	GetVolumeConfig(getVolumeConfigRequest GetVolumeConfigRequest) GetVolumeConfigResponse
	Attach(attachRequest AttachRequest) AttachResponse
	Detach(detachRequest DetachRequest) DetachResponse
}

type UbiquityDockerPluginConfig

type UbiquityDockerPluginConfig struct {
	//Address          string
	Port             int
	PluginsDirectory string
}

type UbiquityPluginConfig

type UbiquityPluginConfig struct {
	DockerPlugin            UbiquityDockerPluginConfig
	LogPath                 string
	UbiquityServer          UbiquityServerConnectionInfo
	SpectrumNfsRemoteConfig SpectrumNfsRemoteConfig
	ScbeRemoteConfig        ScbeRemoteConfig
	LocalHostConfig         LocalHostConfig
	Backends                []string
	LogLevel                string
}

type UbiquityServerConfig

type UbiquityServerConfig struct {
	Port                int
	LogPath             string
	ConfigPath          string
	SpectrumScaleConfig SpectrumScaleConfig
	ScbeConfig          ScbeConfig
	LocalHostConfig     LocalHostConfig
	BrokerConfig        BrokerConfig
	DefaultBackend      string
	LogLevel            string
}

type UbiquityServerConnectionInfo

type UbiquityServerConnectionInfo struct {
	Address string
	Port    int
}

type UnmountRequest

type UnmountRequest struct {
	VolumeConfig map[string]interface{}
}

type UnmountResponse added in v0.4.1

type UnmountResponse struct {
	Error error
}

type Volume

type Volume struct {
	gorm.Model
	Name          string
	CapacityBytes uint64
	Metadata      map[string]string
	Backend       string
	Mountpoint    string
}

Jump to

Keyboard shortcuts

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