29
29
30
30
31
31
class Volume (proto .Message ):
32
- r"""Volume and mount parameters to be associated with a TaskSpec.
33
- A TaskSpec might describe zero, one, or multiple volumes to be
34
- mounted as part of the task.
32
+ r"""Volume describes a volume and parameters for it to be mounted
33
+ to a VM.
35
34
36
35
This message has `oneof`_ fields (mutually exclusive fields).
37
36
For each oneof, at most one member field can be set at the same time.
@@ -42,32 +41,43 @@ class Volume(proto.Message):
42
41
43
42
Attributes:
44
43
nfs (google.cloud.batch_v1alpha.types.NFS):
45
- An NFS source for the volume (could be a
46
- Filestore, for example) .
44
+ A Network File System (NFS) volume. For
45
+ example, a Filestore file share .
47
46
48
47
This field is a member of `oneof`_ ``source``.
49
48
pd (google.cloud.batch_v1alpha.types.PD):
50
- A persistent disk source for the volume .
49
+ Deprecated: please use device_name instead .
51
50
52
51
This field is a member of `oneof`_ ``source``.
53
52
gcs (google.cloud.batch_v1alpha.types.GCS):
54
- A Google Cloud Storage source for the volume.
53
+ A Google Cloud Storage (GCS) volume.
55
54
56
55
This field is a member of `oneof`_ ``source``.
57
56
device_name (str):
58
- Device name of an attached disk
57
+ Device name of an attached disk volume, which should align
58
+ with a device_name specified by
59
+ job.allocation_policy.instances[0].policy.disks[i].device_name
60
+ or defined by the given instance template in
61
+ job.allocation_policy.instances[0].instance_template.
59
62
60
63
This field is a member of `oneof`_ ``source``.
61
64
mount_path (str):
62
- Mount path for the volume, e.g. /mnt/share
65
+ The mount path for the volume, e.g.
66
+ /mnt/disks/share.
63
67
mount_options (MutableSequence[str]):
64
- Mount options For Google Cloud Storage, mount options are
65
- the global options supported by gcsfuse tool. Batch will use
66
- them to mount the volume with the following command:
67
- "gcsfuse [global options] bucket mountpoint". For PD, NFS,
68
- mount options are these supported by /etc/fstab. Batch will
69
- use Fstab to mount such volumes.
70
- https://help.ubuntu.com/community/Fstab
68
+ For Google Cloud Storage (GCS), mount options
69
+ are the options supported by the gcsfuse tool
70
+ (https://github.com/GoogleCloudPlatform/gcsfuse).
71
+ For existing persistent disks, mount options
72
+ provided by the mount command
73
+ (https://man7.org/linux/man-pages/man8/mount.8.html)
74
+ except writing are supported. This is due to
75
+ restrictions of multi-writer mode
76
+ (https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms).
77
+ For other attached disks and Network File System
78
+ (NFS), mount options are these supported by the
79
+ mount command
80
+ (https://man7.org/linux/man-pages/man8/mount.8.html).
71
81
"""
72
82
73
83
nfs : "NFS" = proto .Field (
@@ -104,14 +114,14 @@ class Volume(proto.Message):
104
114
105
115
106
116
class NFS (proto .Message ):
107
- r"""Represents an NFS server and remote path: :<remote_path>
117
+ r"""Represents an NFS volume.
108
118
109
119
Attributes:
110
120
server (str):
111
- URI of the NFS server, e.g. an IP address .
121
+ The IP address of the NFS.
112
122
remote_path (str):
113
- Remote source path exported from NFS, e.g. ,
114
- "/share".
123
+ Remote source path exported from the NFS ,
124
+ e.g., "/share".
115
125
"""
116
126
117
127
server : str = proto .Field (
@@ -125,7 +135,7 @@ class NFS(proto.Message):
125
135
126
136
127
137
class PD (proto .Message ):
128
- r"""Represents a GCP persistent disk
138
+ r"""Deprecated: please use device_name instead.
129
139
130
140
Attributes:
131
141
disk (str):
@@ -155,7 +165,7 @@ class PD(proto.Message):
155
165
156
166
157
167
class GCS (proto .Message ):
158
- r"""Represents a Google Cloud Storage volume source config .
168
+ r"""Represents a Google Cloud Storage volume.
159
169
160
170
Attributes:
161
171
remote_path (str):
0 commit comments