rsync

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: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DriverName is the name of this rsync volume driver implementation
	DriverName = "rsync"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type RsyncConn

type RsyncConn struct {
	sync.Mutex
	// contains filtered or unexported fields
}

RsyncConn is a connection to a rsync volume

func (*RsyncConn) Export

func (c *RsyncConn) Export(label, parent, outdir string) (err error)

Export copys a snapshot

func (*RsyncConn) Import

func (c *RsyncConn) Import(label, indir string) (err error)

Import imports a snapshot

func (*RsyncConn) Name

func (c *RsyncConn) Name() string

Name provides the name of the subvolume

func (*RsyncConn) Path

func (c *RsyncConn) Path() string

Path provides the full path to the subvolume

func (*RsyncConn) RemoveSnapshot

func (c *RsyncConn) RemoveSnapshot(label string) error

RemoveSnapshot removes the snapshot with the given label

func (*RsyncConn) Rollback

func (c *RsyncConn) Rollback(label string) (err error)

Rollback rolls back the volume to the given snapshot

func (*RsyncConn) Snapshot

func (c *RsyncConn) Snapshot(label string) (err error)

Snapshot performs a writable snapshot on the subvolume

func (*RsyncConn) SnapshotPath

func (c *RsyncConn) SnapshotPath(label string) string

func (*RsyncConn) Snapshots

func (c *RsyncConn) Snapshots() ([]string, error)

Snapshots returns the current snapshots on the volume

func (*RsyncConn) Unmount

func (c *RsyncConn) Unmount() error

Unmount deletes the volume and snapshots

type RsyncDriver

type RsyncDriver struct {
	sync.Mutex
}

RsyncDriver is a driver for the rsync volume

func New

func New() (*RsyncDriver, error)

New creates a new RsyncDriver

func (*RsyncDriver) List

func (d *RsyncDriver) List(rootDir string) (result []string)

List lists all of the folders at given root dir

func (*RsyncDriver) Mount

func (d *RsyncDriver) Mount(volumeName, rootDir string) (volume.Volume, error)

Mount creates a new subvolume at given root dir

Jump to

Keyboard shortcuts

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