Class: Google::Apis::NotebooksV2::DataDisk

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/notebooks_v2/classes.rb,
lib/google/apis/notebooks_v2/representations.rb,
lib/google/apis/notebooks_v2/representations.rb

Overview

An instance-attached disk resource.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ DataDisk

Returns a new instance of DataDisk.



339
340
341
# File 'lib/google/apis/notebooks_v2/classes.rb', line 339

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#disk_encryptionString

Optional. Input only. Disk encryption method used on the boot and data disks, defaults to GMEK. Corresponds to the JSON property diskEncryption

Returns:

  • (String)


318
319
320
# File 'lib/google/apis/notebooks_v2/classes.rb', line 318

def disk_encryption
  @disk_encryption
end

#disk_size_gbFixnum

Optional. The size of the disk in GB attached to this VM instance, up to a maximum of 64000 GB (64 TB). If not specified, this defaults to 100. Corresponds to the JSON property diskSizeGb

Returns:

  • (Fixnum)


324
325
326
# File 'lib/google/apis/notebooks_v2/classes.rb', line 324

def disk_size_gb
  @disk_size_gb
end

#disk_typeString

Optional. Input only. Indicates the type of the disk. Corresponds to the JSON property diskType

Returns:

  • (String)


329
330
331
# File 'lib/google/apis/notebooks_v2/classes.rb', line 329

def disk_type
  @disk_type
end

#kms_keyString

Optional. Input only. The KMS key used to encrypt the disks, only applicable if disk_encryption is CMEK. Format: projects/project_id/locations/location /keyRings/key_ring_id/cryptoKeys/key_id`Learn more about using your own encryption keys. Corresponds to the JSON propertykmsKey`

Returns:

  • (String)


337
338
339
# File 'lib/google/apis/notebooks_v2/classes.rb', line 337

def kms_key
  @kms_key
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



344
345
346
347
348
349
# File 'lib/google/apis/notebooks_v2/classes.rb', line 344

def update!(**args)
  @disk_encryption = args[:disk_encryption] if args.key?(:disk_encryption)
  @disk_size_gb = args[:disk_size_gb] if args.key?(:disk_size_gb)
  @disk_type = args[:disk_type] if args.key?(:disk_type)
  @kms_key = args[:kms_key] if args.key?(:kms_key)
end