Batch v1 API - Class Volume (2.9.0)

public sealed class Volume : IMessage<Volume>, IEquatable<Volume>, IDeepCloneable<Volume>, IBufferMessage, IMessage

Reference documentation and code samples for the Batch v1 API class Volume.

Volume describes a volume and parameters for it to be mounted to a VM.

Inheritance

object > Volume

Namespace

Google.Cloud.Batch.V1

Assembly

Google.Cloud.Batch.V1.dll

Constructors

Volume()

public Volume()

Volume(Volume)

public Volume(Volume other)
Parameter
NameDescription
otherVolume

Properties

DeviceName

public string DeviceName { get; set; }

Device name of an attached disk volume, which should align with a device_name specified by job.allocation_policy.instances[0].policy.disks[i].device_name or defined by the given instance template in job.allocation_policy.instances[0].instance_template.

Property Value
TypeDescription
string

Gcs

public GCS Gcs { get; set; }

A Google Cloud Storage (GCS) volume.

Property Value
TypeDescription
GCS

HasDeviceName

public bool HasDeviceName { get; }

Gets whether the "device_name" field is set

Property Value
TypeDescription
bool

MountOptions

public RepeatedField<string> MountOptions { get; }

For Google Cloud Storage (GCS), mount options are the options supported by the gcsfuse tool (https://github.com/GoogleCloudPlatform/gcsfuse). For existing persistent disks, mount options provided by the mount command (https://man7.org/linux/man-pages/man8/mount.8.html) except writing are supported. This is due to restrictions of multi-writer mode (https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms). For other attached disks and Network File System (NFS), mount options are these supported by the mount command (https://man7.org/linux/man-pages/man8/mount.8.html).

Property Value
TypeDescription
RepeatedFieldstring

MountPath

public string MountPath { get; set; }

The mount path for the volume, e.g. /mnt/disks/share.

Property Value
TypeDescription
string

Nfs

public NFS Nfs { get; set; }

A Network File System (NFS) volume. For example, a Filestore file share.

Property Value
TypeDescription
NFS

SourceCase

public Volume.SourceOneofCase SourceCase { get; }
Property Value
TypeDescription
VolumeSourceOneofCase