dfs

package
v0.0.0-...-88aa921 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2015 License: Apache-2.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DockerLatest = "latest"
)

Variables

This section is empty.

Functions

func GetSubvolume

func GetSubvolume(fsType, varpath, serviceID string) (volume.Volume, error)

GetSubvolume gets the path of the *local* volume on the host

func NewLabel

func NewLabel(tenantID string) string

Types

type DatastoreGetter

type DatastoreGetter func() datastore.Context

type DistributedFilesystem

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

func NewDistributedFilesystem

func NewDistributedFilesystem(fsType, varpath, dockerRegistry string, facade facade.FacadeInterface, timeout time.Duration) (*DistributedFilesystem, error)

func (*DistributedFilesystem) Backup

func (dfs *DistributedFilesystem) Backup(dirpath string, last int) (string, error)

Backup backs up serviced, saving the last n snapshots

func (*DistributedFilesystem) Commit

func (dfs *DistributedFilesystem) Commit(dockerID string) (string, error)

Commit will merge a container into existing services' image

func (*DistributedFilesystem) DeleteSnapshot

func (dfs *DistributedFilesystem) DeleteSnapshot(snapshotID string) error

DeleteSnapshot deletes an existing snapshot as identified by its snapshotID

func (*DistributedFilesystem) DeleteSnapshots

func (dfs *DistributedFilesystem) DeleteSnapshots(tenantID string) error

DeleteSnapshots deletes all snapshots relating to a particular tenantID

func (*DistributedFilesystem) GetStatus

func (dfs *DistributedFilesystem) GetStatus(timeout time.Duration) string

func (*DistributedFilesystem) GetVolume

func (dfs *DistributedFilesystem) GetVolume(serviceID string) (volume.Volume, error)

func (*DistributedFilesystem) IsLocked

func (dfs *DistributedFilesystem) IsLocked() (bool, error)

func (*DistributedFilesystem) ListBackups

func (dfs *DistributedFilesystem) ListBackups(dirpath string) ([]dao.BackupFile, error)

ListBackups lists all the backups in a given directory

func (*DistributedFilesystem) ListSnapshots

func (dfs *DistributedFilesystem) ListSnapshots(tenantID string) ([]dao.SnapshotInfo, error)

ListSnapshots lists all the snapshots for a particular tenant

func (*DistributedFilesystem) Lock

func (dfs *DistributedFilesystem) Lock() error

func (*DistributedFilesystem) ResetRegistry

func (dfs *DistributedFilesystem) ResetRegistry() error

ResetRegistry will update the host:port of the docker registry

func (*DistributedFilesystem) Restore

func (dfs *DistributedFilesystem) Restore(filename string) error

func (*DistributedFilesystem) Rollback

func (dfs *DistributedFilesystem) Rollback(snapshotID string, forceRestart bool) error

Rollback rolls back the dfs and docker images to the state of a given snapshot

func (*DistributedFilesystem) Snapshot

func (dfs *DistributedFilesystem) Snapshot(tenantID string, description string) (string, error)

Snapshot takes a snapshot of the dfs as well as the docker images for the given service ID

func (*DistributedFilesystem) Unlock

func (dfs *DistributedFilesystem) Unlock() error

type FileInfoSlice

type FileInfoSlice []os.FileInfo

func (FileInfoSlice) Len

func (p FileInfoSlice) Len() int

func (FileInfoSlice) Less

func (p FileInfoSlice) Less(i, j int) bool

func (FileInfoSlice) Swap

func (p FileInfoSlice) Swap(i, j int)

type ServiceVolumeGetter

type ServiceVolumeGetter func(fsType, varpath, serviceID string) (volume.Volume, error)

type SnapshotMetadata

type SnapshotMetadata struct {
	Description string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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