forked from pachyderm/pachyderm
/
fuse.go
34 lines (30 loc) · 973 Bytes
/
fuse.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package fuse
import (
pfsclient "github.com/pachyderm/pachyderm/src/client/pfs"
)
type Mounter interface {
// Mount mounts a repository available as a fuse filesystem at mountPoint.
// Mount blocks and will return once the volume is unmounted.
MountAndCreate(
mountPoint string,
shard *pfsclient.Shard,
commitMounts []*CommitMount, // nil means mount all commits
ready chan bool,
debug bool,
) error
Mount(
mountPoint string,
shard *pfsclient.Shard,
commitMounts []*CommitMount, // nil means mount all commits
ready chan bool,
debug bool,
) error
// Unmount unmounts a mounted filesystem (duh).
// There's nothing special about this unmount, it's just doing a syscall under the hood.
Unmount(mountPoint string) error
}
// NewMounter creates a new Mounter.
// Address can be left blank, it's used only for aesthetic purposes.
func NewMounter(address string, apiClient pfsclient.APIClient) Mounter {
return newMounter(address, apiClient)
}