Class: Google::Apis::ComputeAlpha::InstanceFlexibilityPolicyInstanceSelection

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

Overview

Specification of machine type to use. Every position inside this message is an alternative. The count specified in the shape flexibility must not exceed the number of entries in per_instance_properties or the capacity of the name_pattern, if used.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ InstanceFlexibilityPolicyInstanceSelection

Returns a new instance of InstanceFlexibilityPolicyInstanceSelection.



27447
27448
27449
# File 'lib/google/apis/compute_alpha/classes.rb', line 27447

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

Instance Attribute Details

#disksArray<Google::Apis::ComputeAlpha::AttachedDisk>

Disks to be attached to the instances created from in this selection. They override the disks specified in the instance properties. Corresponds to the JSON property disks



27424
27425
27426
# File 'lib/google/apis/compute_alpha/classes.rb', line 27424

def disks
  @disks
end

#machine_typesArray<String>

Alternative machine types to use for instances that are created from these properties. This field only accepts a machine type names, for example n2-standard-4 and not URLs or partial URLs. Corresponds to the JSON property machineTypes

Returns:

  • (Array<String>)


27431
27432
27433
# File 'lib/google/apis/compute_alpha/classes.rb', line 27431

def machine_types
  @machine_types
end

#min_cpu_platformString

Name of the minimum CPU platform to be used by this instance selection. e.g. 'Intel Ice Lake'. Corresponds to the JSON property minCpuPlatform

Returns:

  • (String)


27437
27438
27439
# File 'lib/google/apis/compute_alpha/classes.rb', line 27437

def min_cpu_platform
  @min_cpu_platform
end

#rankFixnum

Rank when prioritizing the shape flexibilities. The instance selections with rank are considered first, in the ascending order of the rank. If not set, defaults to 0. Corresponds to the JSON property rank

Returns:

  • (Fixnum)


27445
27446
27447
# File 'lib/google/apis/compute_alpha/classes.rb', line 27445

def rank
  @rank
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



27452
27453
27454
27455
27456
27457
# File 'lib/google/apis/compute_alpha/classes.rb', line 27452

def update!(**args)
  @disks = args[:disks] if args.key?(:disks)
  @machine_types = args[:machine_types] if args.key?(:machine_types)
  @min_cpu_platform = args[:min_cpu_platform] if args.key?(:min_cpu_platform)
  @rank = args[:rank] if args.key?(:rank)
end