Google Cloud Compute V1 API - Class Google::Cloud::Compute::V1::InstanceGroupManager (v2.15.0)

Reference documentation and code samples for the Google Cloud Compute V1 API class Google::Cloud::Compute::V1::InstanceGroupManager.

Represents a Managed Instance Group resource. An instance group is a collection of VM instances that you can manage as a single entity. For more information, read Instance groups. For zonal Managed Instance Group, use the instanceGroupManagers resource. For regional Managed Instance Group, use the regionInstanceGroupManagers resource.

Inherits

  • Object

Extended By

  • Google::Protobuf::MessageExts::ClassMethods

Includes

  • Google::Protobuf::MessageExts

Methods

#all_instances_config

def all_instances_config() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerAllInstancesConfig
Returns

#all_instances_config=

def all_instances_config=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerAllInstancesConfig
Parameter
Returns

#auto_healing_policies

def auto_healing_policies() -> ::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerAutoHealingPolicy>
Returns

#auto_healing_policies=

def auto_healing_policies=(value) -> ::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerAutoHealingPolicy>
Parameter
Returns

#base_instance_name

def base_instance_name() -> ::String
Returns
  • (::String) — The base instance name is a prefix that you want to attach to the names of all VMs in a MIG. The maximum character length is 58 and the name must comply with RFC1035 format. When a VM is created in the group, the MIG appends a hyphen and a random four-character string to the base instance name. If you want the MIG to assign sequential numbers instead of a random string, then end the base instance name with a hyphen followed by one or more hash symbols. The hash symbols indicate the number of digits. For example, a base instance name of "vm-###" results in "vm-001" as a VM name. @pattern a-z

#base_instance_name=

def base_instance_name=(value) -> ::String
Parameter
  • value (::String) — The base instance name is a prefix that you want to attach to the names of all VMs in a MIG. The maximum character length is 58 and the name must comply with RFC1035 format. When a VM is created in the group, the MIG appends a hyphen and a random four-character string to the base instance name. If you want the MIG to assign sequential numbers instead of a random string, then end the base instance name with a hyphen followed by one or more hash symbols. The hash symbols indicate the number of digits. For example, a base instance name of "vm-###" results in "vm-001" as a VM name. @pattern a-z
Returns
  • (::String) — The base instance name is a prefix that you want to attach to the names of all VMs in a MIG. The maximum character length is 58 and the name must comply with RFC1035 format. When a VM is created in the group, the MIG appends a hyphen and a random four-character string to the base instance name. If you want the MIG to assign sequential numbers instead of a random string, then end the base instance name with a hyphen followed by one or more hash symbols. The hash symbols indicate the number of digits. For example, a base instance name of "vm-###" results in "vm-001" as a VM name. @pattern a-z

#creation_timestamp

def creation_timestamp() -> ::String
Returns
  • (::String) — [Output Only] The creation timestamp for this managed instance group in RFC3339 text format.

#creation_timestamp=

def creation_timestamp=(value) -> ::String
Parameter
  • value (::String) — [Output Only] The creation timestamp for this managed instance group in RFC3339 text format.
Returns
  • (::String) — [Output Only] The creation timestamp for this managed instance group in RFC3339 text format.

#current_actions

def current_actions() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerActionsSummary
Returns

#current_actions=

def current_actions=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerActionsSummary
Parameter
Returns

#description

def description() -> ::String
Returns
  • (::String) — An optional description of this resource.

#description=

def description=(value) -> ::String
Parameter
  • value (::String) — An optional description of this resource.
Returns
  • (::String) — An optional description of this resource.

#distribution_policy

def distribution_policy() -> ::Google::Cloud::Compute::V1::DistributionPolicy
Returns

#distribution_policy=

def distribution_policy=(value) -> ::Google::Cloud::Compute::V1::DistributionPolicy
Parameter
Returns

#fingerprint

def fingerprint() -> ::String
Returns
  • (::String) — Fingerprint of this resource. This field may be used in optimistic locking. It will be ignored when inserting an InstanceGroupManager. An up-to-date fingerprint must be provided in order to update the InstanceGroupManager, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an InstanceGroupManager.

#fingerprint=

def fingerprint=(value) -> ::String
Parameter
  • value (::String) — Fingerprint of this resource. This field may be used in optimistic locking. It will be ignored when inserting an InstanceGroupManager. An up-to-date fingerprint must be provided in order to update the InstanceGroupManager, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an InstanceGroupManager.
Returns
  • (::String) — Fingerprint of this resource. This field may be used in optimistic locking. It will be ignored when inserting an InstanceGroupManager. An up-to-date fingerprint must be provided in order to update the InstanceGroupManager, otherwise the request will fail with error 412 conditionNotMet. To see the latest fingerprint, make a get() request to retrieve an InstanceGroupManager.

#id

def id() -> ::Integer
Returns
  • (::Integer) — [Output Only] A unique identifier for this resource type. The server generates this identifier.

#id=

def id=(value) -> ::Integer
Parameter
  • value (::Integer) — [Output Only] A unique identifier for this resource type. The server generates this identifier.
Returns
  • (::Integer) — [Output Only] A unique identifier for this resource type. The server generates this identifier.

#instance_flexibility_policy

def instance_flexibility_policy() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerInstanceFlexibilityPolicy
Returns

#instance_flexibility_policy=

def instance_flexibility_policy=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerInstanceFlexibilityPolicy
Parameter
Returns

#instance_group

def instance_group() -> ::String
Returns
  • (::String) — [Output Only] The URL of the Instance Group resource.

#instance_group=

def instance_group=(value) -> ::String
Parameter
  • value (::String) — [Output Only] The URL of the Instance Group resource.
Returns
  • (::String) — [Output Only] The URL of the Instance Group resource.

#instance_lifecycle_policy

def instance_lifecycle_policy() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerInstanceLifecyclePolicy
Returns

#instance_lifecycle_policy=

def instance_lifecycle_policy=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerInstanceLifecyclePolicy
Parameter
Returns

#instance_template

def instance_template() -> ::String
Returns
  • (::String) — The URL of the instance template that is specified for this managed instance group. The group uses this template to create all new instances in the managed instance group. The templates for existing instances in the group do not change unless you run recreateInstances, run applyUpdatesToInstances, or set the group's updatePolicy.type to PROACTIVE.

#instance_template=

def instance_template=(value) -> ::String
Parameter
  • value (::String) — The URL of the instance template that is specified for this managed instance group. The group uses this template to create all new instances in the managed instance group. The templates for existing instances in the group do not change unless you run recreateInstances, run applyUpdatesToInstances, or set the group's updatePolicy.type to PROACTIVE.
Returns
  • (::String) — The URL of the instance template that is specified for this managed instance group. The group uses this template to create all new instances in the managed instance group. The templates for existing instances in the group do not change unless you run recreateInstances, run applyUpdatesToInstances, or set the group's updatePolicy.type to PROACTIVE.

#kind

def kind() -> ::String
Returns
  • (::String) — [Output Only] The resource type, which is always compute#instanceGroupManager for managed instance groups.

#kind=

def kind=(value) -> ::String
Parameter
  • value (::String) — [Output Only] The resource type, which is always compute#instanceGroupManager for managed instance groups.
Returns
  • (::String) — [Output Only] The resource type, which is always compute#instanceGroupManager for managed instance groups.

#list_managed_instances_results

def list_managed_instances_results() -> ::String
Returns
  • (::String) — Pagination behavior of the listManagedInstances API method for this managed instance group. Check the ListManagedInstancesResults enum for the list of possible values.

#list_managed_instances_results=

def list_managed_instances_results=(value) -> ::String
Parameter
  • value (::String) — Pagination behavior of the listManagedInstances API method for this managed instance group. Check the ListManagedInstancesResults enum for the list of possible values.
Returns
  • (::String) — Pagination behavior of the listManagedInstances API method for this managed instance group. Check the ListManagedInstancesResults enum for the list of possible values.

#name

def name() -> ::String
Returns
  • (::String) — The name of the managed instance group. The name must be 1-63 characters long, and comply with RFC1035.

#name=

def name=(value) -> ::String
Parameter
  • value (::String) — The name of the managed instance group. The name must be 1-63 characters long, and comply with RFC1035.
Returns
  • (::String) — The name of the managed instance group. The name must be 1-63 characters long, and comply with RFC1035.

#named_ports

def named_ports() -> ::Array<::Google::Cloud::Compute::V1::NamedPort>
Returns

#named_ports=

def named_ports=(value) -> ::Array<::Google::Cloud::Compute::V1::NamedPort>
Parameter
Returns

#region

def region() -> ::String
Returns
  • (::String) — [Output Only] The URL of the region where the managed instance group resides (for regional resources).

#region=

def region=(value) -> ::String
Parameter
  • value (::String) — [Output Only] The URL of the region where the managed instance group resides (for regional resources).
Returns
  • (::String) — [Output Only] The URL of the region where the managed instance group resides (for regional resources).

#satisfies_pzi

def satisfies_pzi() -> ::Boolean
Returns
  • (::Boolean) — [Output Only] Reserved for future use.

#satisfies_pzi=

def satisfies_pzi=(value) -> ::Boolean
Parameter
  • value (::Boolean) — [Output Only] Reserved for future use.
Returns
  • (::Boolean) — [Output Only] Reserved for future use.

#satisfies_pzs

def satisfies_pzs() -> ::Boolean
Returns
  • (::Boolean) — [Output Only] Reserved for future use.

#satisfies_pzs=

def satisfies_pzs=(value) -> ::Boolean
Parameter
  • value (::Boolean) — [Output Only] Reserved for future use.
Returns
  • (::Boolean) — [Output Only] Reserved for future use.
def self_link() -> ::String
Returns
  • (::String) — [Output Only] The URL for this managed instance group. The server defines this URL.
def self_link=(value) -> ::String
Parameter
  • value (::String) — [Output Only] The URL for this managed instance group. The server defines this URL.
Returns
  • (::String) — [Output Only] The URL for this managed instance group. The server defines this URL.

#standby_policy

def standby_policy() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerStandbyPolicy
Returns

#standby_policy=

def standby_policy=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerStandbyPolicy
Parameter
Returns

#stateful_policy

def stateful_policy() -> ::Google::Cloud::Compute::V1::StatefulPolicy
Returns

#stateful_policy=

def stateful_policy=(value) -> ::Google::Cloud::Compute::V1::StatefulPolicy
Parameter
Returns

#status

def status() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerStatus
Returns

#status=

def status=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerStatus
Parameter
Returns

#target_pools

def target_pools() -> ::Array<::String>
Returns
  • (::Array<::String>) — The URLs for all TargetPool resources to which instances in the instanceGroup field are added. The target pools automatically apply to all of the instances in the managed instance group.

#target_pools=

def target_pools=(value) -> ::Array<::String>
Parameter
  • value (::Array<::String>) — The URLs for all TargetPool resources to which instances in the instanceGroup field are added. The target pools automatically apply to all of the instances in the managed instance group.
Returns
  • (::Array<::String>) — The URLs for all TargetPool resources to which instances in the instanceGroup field are added. The target pools automatically apply to all of the instances in the managed instance group.

#target_size

def target_size() -> ::Integer
Returns
  • (::Integer) — The target number of running instances for this managed instance group. You can reduce this number by using the instanceGroupManager deleteInstances or abandonInstances methods. Resizing the group also changes this number.

#target_size=

def target_size=(value) -> ::Integer
Parameter
  • value (::Integer) — The target number of running instances for this managed instance group. You can reduce this number by using the instanceGroupManager deleteInstances or abandonInstances methods. Resizing the group also changes this number.
Returns
  • (::Integer) — The target number of running instances for this managed instance group. You can reduce this number by using the instanceGroupManager deleteInstances or abandonInstances methods. Resizing the group also changes this number.

#target_stopped_size

def target_stopped_size() -> ::Integer
Returns
  • (::Integer) — The target number of stopped instances for this managed instance group. This number changes when you: - Stop instance using the stopInstances method or start instances using the startInstances method. - Manually change the targetStoppedSize using the update method.

#target_stopped_size=

def target_stopped_size=(value) -> ::Integer
Parameter
  • value (::Integer) — The target number of stopped instances for this managed instance group. This number changes when you: - Stop instance using the stopInstances method or start instances using the startInstances method. - Manually change the targetStoppedSize using the update method.
Returns
  • (::Integer) — The target number of stopped instances for this managed instance group. This number changes when you: - Stop instance using the stopInstances method or start instances using the startInstances method. - Manually change the targetStoppedSize using the update method.

#target_suspended_size

def target_suspended_size() -> ::Integer
Returns
  • (::Integer) — The target number of suspended instances for this managed instance group. This number changes when you: - Suspend instance using the suspendInstances method or resume instances using the resumeInstances method. - Manually change the targetSuspendedSize using the update method.

#target_suspended_size=

def target_suspended_size=(value) -> ::Integer
Parameter
  • value (::Integer) — The target number of suspended instances for this managed instance group. This number changes when you: - Suspend instance using the suspendInstances method or resume instances using the resumeInstances method. - Manually change the targetSuspendedSize using the update method.
Returns
  • (::Integer) — The target number of suspended instances for this managed instance group. This number changes when you: - Suspend instance using the suspendInstances method or resume instances using the resumeInstances method. - Manually change the targetSuspendedSize using the update method.

#update_policy

def update_policy() -> ::Google::Cloud::Compute::V1::InstanceGroupManagerUpdatePolicy
Returns

#update_policy=

def update_policy=(value) -> ::Google::Cloud::Compute::V1::InstanceGroupManagerUpdatePolicy
Parameter
Returns

#versions

def versions() -> ::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerVersion>
Returns
  • (::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerVersion>) — Specifies the instance templates used by this managed instance group to create instances. Each version is defined by an instanceTemplate and a name. Every version can appear at most once per instance group. This field overrides the top-level instanceTemplate field. Read more about the relationships between these fields. Exactly one version must leave the targetSize field unset. That version will be applied to all remaining instances. For more information, read about canary updates.

#versions=

def versions=(value) -> ::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerVersion>
Parameter
  • value (::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerVersion>) — Specifies the instance templates used by this managed instance group to create instances. Each version is defined by an instanceTemplate and a name. Every version can appear at most once per instance group. This field overrides the top-level instanceTemplate field. Read more about the relationships between these fields. Exactly one version must leave the targetSize field unset. That version will be applied to all remaining instances. For more information, read about canary updates.
Returns
  • (::Array<::Google::Cloud::Compute::V1::InstanceGroupManagerVersion>) — Specifies the instance templates used by this managed instance group to create instances. Each version is defined by an instanceTemplate and a name. Every version can appear at most once per instance group. This field overrides the top-level instanceTemplate field. Read more about the relationships between these fields. Exactly one version must leave the targetSize field unset. That version will be applied to all remaining instances. For more information, read about canary updates.

#zone

def zone() -> ::String
Returns
  • (::String) — [Output Only] The URL of a zone where the managed instance group is located (for zonal resources).

#zone=

def zone=(value) -> ::String
Parameter
  • value (::String) — [Output Only] The URL of a zone where the managed instance group is located (for zonal resources).
Returns
  • (::String) — [Output Only] The URL of a zone where the managed instance group is located (for zonal resources).