Class: Google::Apis::BaremetalsolutionV1alpha1::VolumeConfig

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

Overview

Configuration parameters for a new volume.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ VolumeConfig

Returns a new instance of VolumeConfig.



1067
1068
1069
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1067

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

Instance Attribute Details

#idString

A transient unique identifier to identify a volume within an ProvisioningConfig request. Corresponds to the JSON property id

Returns:

  • (String)


1023
1024
1025
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1023

def id
  @id
end

#locationString

Location where to deploy the volume. Corresponds to the JSON property location

Returns:

  • (String)


1028
1029
1030
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1028

def location
  @location
end

#lun_rangesArray<Google::Apis::BaremetalsolutionV1alpha1::LunRange>

LUN ranges to be configured. Set only when protocol is PROTOCOL_FC. Corresponds to the JSON property lunRanges



1033
1034
1035
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1033

def lun_ranges
  @lun_ranges
end

#machine_idsArray<String>

Machine ids connected to this volume. Set only when protocol is PROTOCOL_FC. Corresponds to the JSON property machineIds

Returns:

  • (Array<String>)


1038
1039
1040
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1038

def machine_ids
  @machine_ids
end

#nfs_exportsArray<Google::Apis::BaremetalsolutionV1alpha1::NfsExport>

NFS exports. Set only when protocol is PROTOCOL_NFS. Corresponds to the JSON property nfsExports



1043
1044
1045
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1043

def nfs_exports
  @nfs_exports
end

#protocolString

Volume protocol. Corresponds to the JSON property protocol

Returns:

  • (String)


1048
1049
1050
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1048

def protocol
  @protocol
end

#size_gbFixnum

The requested size of this volume, in GB. This will be updated in a later iteration with a generic size field. Corresponds to the JSON property sizeGb

Returns:

  • (Fixnum)


1054
1055
1056
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1054

def size_gb
  @size_gb
end

#snapshots_enabledBoolean Also known as: snapshots_enabled?

Whether snapshots should be enabled. Corresponds to the JSON property snapshotsEnabled

Returns:

  • (Boolean)


1059
1060
1061
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1059

def snapshots_enabled
  @snapshots_enabled
end

#typeString

The type of this Volume. Corresponds to the JSON property type

Returns:

  • (String)


1065
1066
1067
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1065

def type
  @type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
# File 'lib/google/apis/baremetalsolution_v1alpha1/classes.rb', line 1072

def update!(**args)
  @id = args[:id] if args.key?(:id)
  @location = args[:location] if args.key?(:location)
  @lun_ranges = args[:lun_ranges] if args.key?(:lun_ranges)
  @machine_ids = args[:machine_ids] if args.key?(:machine_ids)
  @nfs_exports = args[:nfs_exports] if args.key?(:nfs_exports)
  @protocol = args[:protocol] if args.key?(:protocol)
  @size_gb = args[:size_gb] if args.key?(:size_gb)
  @snapshots_enabled = args[:snapshots_enabled] if args.key?(:snapshots_enabled)
  @type = args[:type] if args.key?(:type)
end