Documentation ¶
Index ¶
- Variables
- type GlusterDriver
- func (d *GlusterDriver) Capabilities() *volume.CapabilitiesResponse
- func (d *GlusterDriver) Create(r *volume.CreateRequest) error
- func (d *GlusterDriver) Get(r *volume.GetRequest) (*volume.GetResponse, error)
- func (d *GlusterDriver) GetLock() *sync.RWMutex
- func (d *GlusterDriver) GetMounts() map[string]common.Mount
- func (d *GlusterDriver) GetVolumes() map[string]common.Volume
- func (d *GlusterDriver) List() (*volume.ListResponse, error)
- func (d *GlusterDriver) Mount(r *volume.MountRequest) (*volume.MountResponse, error)
- func (d *GlusterDriver) Path(r *volume.PathRequest) (*volume.PathResponse, error)
- func (d *GlusterDriver) Remove(r *volume.RemoveRequest) error
- func (d *GlusterDriver) RunCmd(cmd string) error
- func (d *GlusterDriver) SaveConfig() error
- func (d *GlusterDriver) Unmount(r *volume.UnmountRequest) error
- type GlusterMountpoint
- type GlusterPersistence
- type GlusterVolume
Constants ¶
This section is empty.
Variables ¶
View Source
var ( //MountTimeout timeout before killing a mount try in seconds MountTimeout = 30 //CfgVersion current config version compat CfgVersion = 1 //CfgFolder config folder CfgFolder = "/etc/docker-volumes/gluster/" )
Functions ¶
This section is empty.
Types ¶
type GlusterDriver ¶
type GlusterDriver struct {
// contains filtered or unexported fields
}
GlusterDriver the global driver responding to call
func Init ¶
func Init(root string, mountUniqName bool) *GlusterDriver
Init start all needed deps and serve response to API call
func (*GlusterDriver) Capabilities ¶
func (d *GlusterDriver) Capabilities() *volume.CapabilitiesResponse
Capabilities Send capabilities of the local driver
func (*GlusterDriver) Create ¶
func (d *GlusterDriver) Create(r *volume.CreateRequest) error
Create create and init the requested volume
func (*GlusterDriver) Get ¶
func (d *GlusterDriver) Get(r *volume.GetRequest) (*volume.GetResponse, error)
Get get info on the requested volume
func (*GlusterDriver) GetLock ¶ added in v1.0.7
func (d *GlusterDriver) GetLock() *sync.RWMutex
func (*GlusterDriver) GetMounts ¶ added in v1.0.7
func (d *GlusterDriver) GetMounts() map[string]common.Mount
func (*GlusterDriver) GetVolumes ¶ added in v1.0.7
func (d *GlusterDriver) GetVolumes() map[string]common.Volume
func (*GlusterDriver) List ¶
func (d *GlusterDriver) List() (*volume.ListResponse, error)
List volumes handled by these driver
func (*GlusterDriver) Mount ¶
func (d *GlusterDriver) Mount(r *volume.MountRequest) (*volume.MountResponse, error)
Mount mount the requested volume
func (*GlusterDriver) Path ¶
func (d *GlusterDriver) Path(r *volume.PathRequest) (*volume.PathResponse, error)
Path get path of the requested volume
func (*GlusterDriver) Remove ¶
func (d *GlusterDriver) Remove(r *volume.RemoveRequest) error
Remove remove the requested volume
func (*GlusterDriver) RunCmd ¶ added in v1.0.7
func (d *GlusterDriver) RunCmd(cmd string) error
RunCmd run deamon in context of this gvfs drive with custome env
func (*GlusterDriver) SaveConfig ¶ added in v1.0.7
func (d *GlusterDriver) SaveConfig() error
SaveConfig stroe config/state in file //TODO put inside common
func (*GlusterDriver) Unmount ¶
func (d *GlusterDriver) Unmount(r *volume.UnmountRequest) error
Unmount unmount the requested volume
type GlusterMountpoint ¶ added in v1.0.7
func (*GlusterMountpoint) GetConnections ¶ added in v1.0.7
func (d *GlusterMountpoint) GetConnections() int
func (*GlusterMountpoint) GetPath ¶ added in v1.0.7
func (d *GlusterMountpoint) GetPath() string
func (*GlusterMountpoint) SetConnections ¶ added in v1.0.7
func (d *GlusterMountpoint) SetConnections(n int)
type GlusterPersistence ¶
type GlusterPersistence struct { Version int `json:"version"` Volumes map[string]*GlusterVolume `json:"volumes"` Mounts map[string]*GlusterMountpoint `json:"mounts"` }
GlusterPersistence represent struct of persistence file
type GlusterVolume ¶ added in v1.0.7
type GlusterVolume struct { VolumeURI string `json:"voluri"` Mount string `json:"mount"` Connections int `json:"connections"` }
func (*GlusterVolume) GetConnections ¶ added in v1.0.7
func (v *GlusterVolume) GetConnections() int
func (*GlusterVolume) GetMount ¶ added in v1.0.7
func (v *GlusterVolume) GetMount() string
func (*GlusterVolume) GetRemote ¶ added in v1.0.7
func (v *GlusterVolume) GetRemote() string
func (*GlusterVolume) GetStatus ¶ added in v1.0.7
func (v *GlusterVolume) GetStatus() map[string]interface{}
func (*GlusterVolume) SetConnections ¶ added in v1.0.7
func (v *GlusterVolume) SetConnections(n int)
Click to show internal directories.
Click to hide internal directories.