gcloud compute instance-groups managed update-autoscaling

NAME
gcloud compute instance-groups managed update-autoscaling - update autoscaling parameters of a managed instance group
SYNOPSIS
gcloud compute instance-groups managed update-autoscaling NAME [--mode=MODE] [--clear-scale-in-control     | --scale-in-control=[max-scaled-in-replicas=MAX-SCALED-IN-REPLICAS],[max-scaled-in-replicas-percent=MAX-SCALED-IN-REPLICAS-PERCENT],[time-window=TIME-WINDOW]] [--region=REGION     | --zone=ZONE] [GCLOUD_WIDE_FLAG]
DESCRIPTION
gcloud compute instance-groups managed update-autoscaling updates autoscaling parameters of specified managed instance group.

Autoscalers can use one or more policies listed below. Information on using multiple policies can be found here: https://cloud.google.com/compute/docs/autoscaler/multiple-policies

In contrast to gcloud compute instance-groups managed set-autoscaling, this command only updates specified fields. For instance:

gcloud compute instance-groups managed update-autoscaling  --mode only-scale-out

would change the mode field of the autoscaler policy, but leave the rest of the settings intact.

POSITIONAL ARGUMENTS
NAME
Name of the managed instance group to operate on.
FLAGS
--mode=MODE
Set the mode of an autoscaler for a managed instance group.

You can turn off or restrict MIG autoscaler activities without affecting your autoscaler configuration. The autoscaler configuration persists while the activities are turned off or restricted, and the activities resume when the autoscaler is turned on again or when the restrictions are lifted.

MODE must be one of:

off
Turns off autoscaling, while keeping the new configuration.
on
Permits autoscaling to scale out and in (default for new autoscalers).
only-scale-out
Permits autoscaling to scale only out and not in.
only-up
(DEPRECATED) Permits autoscaling to scale only out and not in.
  Value `only-up` is deprecated. Use `--mode only-scale-out`
  instead.
At most one of these may be specified:
--clear-scale-in-control
If specified, the scale-in-control field will be cleared. Using this flag will remove any configuration set by --scale-in-control flag.
--scale-in-control=[max-scaled-in-replicas=MAX-SCALED-IN-REPLICAS],[max-scaled-in-replicas-percent=MAX-SCALED-IN-REPLICAS-PERCENT],[time-window=TIME-WINDOW]
Configuration that allows slower scale in so that even if Autoscaler recommends an abrupt scale in of a managed instance group, it will be throttled as specified by the parameters.
max-scaled-in-replicas
Maximum allowed number of VMs that can be deducted from the peak recommendation during the window. Possibly all these VMs can be deleted at once so the application needs to be prepared to lose that many VMs in one step. Mutually exclusive with 'max-scaled-in-replicas-percent'.
max-scaled-in-replicas-percent
Maximum allowed percent of VMs that can be deducted from the peak recommendation during the window. Possibly all these VMs can be deleted at once so the application needs to be prepared to lose that many VMs in one step. Mutually exclusive with 'max-scaled-in-replicas'.
time-window
How long back autoscaling should look when computing recommendations. The autoscaler will not resize below the maximum allowed deduction subtracted from the peak size observed in this period. Measured in seconds.
At most one of these may be specified:
--region=REGION
Region of the managed instance group to operate on. If not specified, you may be prompted to select a region.

A list of regions can be fetched by running:

gcloud compute regions list

Overrides the default compute/region property value for this command invocation.

--zone=ZONE
Zone of the managed instance group to operate on. If not specified, you may be prompted to select a zone.

A list of zones can be fetched by running:

gcloud compute zones list

Overrides the default compute/zone property value for this command invocation.

GCLOUD WIDE FLAGS
These flags are available to all commands: --account, --billing-project, --configuration, --flags-file, --flatten, --format, --help, --impersonate-service-account, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity.

Run $ gcloud help for details.

EXAMPLES
To update an existing instance group:
gcloud compute instance-groups managed update-autoscaling  --mode=only-scale-out
NOTES
These variants are also available:
gcloud alpha compute instance-groups managed update-autoscaling
gcloud beta compute instance-groups managed update-autoscaling