-
Notifications
You must be signed in to change notification settings - Fork 0
/
filesystem.go
54 lines (42 loc) · 1.67 KB
/
filesystem.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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
// Copyright 2015 Canonical Ltd.
// Licensed under the AGPLv3, see LICENCE file for details.
package storage
import "github.com/juju/names/v4"
// Filesystem identifies and describes a filesystem, either local or remote
// (NFS, Ceph etc).
type Filesystem struct {
// Tag is a unique name assigned by Juju to the filesystem.
Tag names.FilesystemTag
// Volume is the tag of the volume that backs the filesystem, if any.
Volume names.VolumeTag
FilesystemInfo
}
// Filesystem describes a filesystem, either local or remote (NFS, Ceph etc).
type FilesystemInfo struct {
// FilesystemId is a unique provider-supplied ID for the filesystem.
// FilesystemId is required to be unique for the lifetime of the
// filesystem, but may be reused.
FilesystemId string
// Size is the size of the filesystem, in MiB.
Size uint64
}
// FilesystemAttachment describes machine-specific filesystem attachment information,
// including how the filesystem is exposed on the machine.
type FilesystemAttachment struct {
// Filesystem is the unique tag assigned by Juju for the filesystem
// that this attachment corresponds to.
Filesystem names.FilesystemTag
// Machine is the unique tag assigned by Juju for the machine that
// this attachment corresponds to.
Machine names.Tag
FilesystemAttachmentInfo
}
// FilesystemAttachmentInfo describes machine-specific filesystem attachment
// information, including how the filesystem is exposed on the machine.
type FilesystemAttachmentInfo struct {
// Path is the path at which the filesystem is mounted on the machine
// that this attachment corresponds to.
Path string
// ReadOnly indicates that the filesystem is mounted read-only.
ReadOnly bool
}