Class: Google::Apis::HypercomputeclusterV1::NewSpotInstancesConfig
- Inherits:
-
Object
- Object
- Google::Apis::HypercomputeclusterV1::NewSpotInstancesConfig
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/hypercomputecluster_v1/classes.rb,
lib/google/apis/hypercomputecluster_v1/representations.rb,
lib/google/apis/hypercomputecluster_v1/representations.rb
Overview
When set in a ComputeResourceConfig, indicates that spot VM instances should be created.
Instance Attribute Summary collapse
-
#machine_type ⇒ String
Required.
-
#termination_action ⇒ String
Optional.
-
#zone ⇒ String
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ NewSpotInstancesConfig
constructor
A new instance of NewSpotInstancesConfig.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ NewSpotInstancesConfig
Returns a new instance of NewSpotInstancesConfig.
1348 1349 1350 |
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1348 def initialize(**args) update!(**args) end |
Instance Attribute Details
#machine_type ⇒ String
Required. Immutable. Name of the Compute Engine machine type to use, e.g. n2-standard-2.
Corresponds to the JSON property machineType
1333 1334 1335 |
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1333 def machine_type @machine_type end |
#termination_action ⇒ String
Optional. Termination action for the instance. If not specified, Compute
Engine sets the termination action to DELETE.
Corresponds to the JSON property terminationAction
1339 1340 1341 |
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1339 def termination_action @termination_action end |
#zone ⇒ String
Required. Immutable. Name of the zone in which VM instances should run, e.g.,
us-central1-a. Must be in the same region as the cluster, and must match the
zone of any other resources specified in the cluster.
Corresponds to the JSON property zone
1346 1347 1348 |
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1346 def zone @zone end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1353 1354 1355 1356 1357 |
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1353 def update!(**args) @machine_type = args[:machine_type] if args.key?(:machine_type) @termination_action = args[:termination_action] if args.key?(:termination_action) @zone = args[:zone] if args.key?(:zone) end |