Configure a Compute Engine MIG in Application Design Center

A Compute Engine managed instance group (MIG) is a collection of VM instances that use load balancing and automated services, like autoscaling and autohealing. With a MIG, you can manage a group of VM instances as one entity.

For more information, see the following:

Required configuration parameters

If your template includes a Compute Engine MIG component, you must configure the following parameters before you deploy.

Parameter name

Description and constraints

Background information

Project ID

The App Hub service project where you want to create the Compute Engine MIG.

Set up App Hub

Region

region About Regional MIGs

Instance Template

instanceTemplate About Instance Templates

Optional configuration parameters

The following parameters are optional. To display advanced parameters, in the Configuration area, select Show advanced fields.

Feature

Parameter name

Description and constraint information

Background information

MIG name

name

Hostname

Hostname prefix for instances

Target Size

targetSize Create a MIG with autoscaling enabled.

Max Replicas

autoscalingPolicy.maxNumReplicas Create a MIG with autoscaling enabled

Min replicas

autoscalingPolicy.minNumReplicas Create a MIG with autoscaling enabled

Autoscaling Mode

autoscalingPolicy.mode Autoscaling mode

Target Pools

targetPools[] Add a managed instance group to a target pool

Distribution Policy Target Shape

distributionPolicy.targetShape feedbackRegional MIG target distribution shape

Distribution Policy Zones

distributionPolicy.zones[] Set a target distribution shape for VMs in a regional MIG

Stateful Disks

Device Name

statefulPolicy.preservedState.disks[] Configuring stateful persistent disks in MIGs

Delete Rule

statefulPolicy.preservedState.disks[].autoDelete Configuring stateful persistent disks in MIGs

Stateful IPs

Interface Name

statefulPolicy.preservedState.internalIPs[] Configuring stateful IP addresses in MIGs

Delete Rule

statefulPolicy.preservedState.internalIPs[].autoDelete Configuring stateful IP addresses in MIGs

Is External

statefulPolicy.preservedState.externalIPs[] Configuring stateful IP addresses in MIGs

Update Policy

Max Surge Fixed

updatePolicy.maxSurge.fixed Maximum surge

Instance Redistribution Type

updatePolicy.instanceRedistributionType Proactive instance redistribution

Max Surge Percent

updatePolicy.maxSurge.percent Maximum surge

Max Unavailable Fixed

updatePolicy.maxUnavailable.fixed Maximum unavailable

Max Unavailable Percent

updatePolicy.maxUnavailable.percent Maximum unavailable

Min Ready Sec

updatePolicy.minReadySec Minimum wait time

Replacement Method

updatePolicy.replacementMethod Replacement method

Minimal Action

updatePolicy.minimalAction Minimal action

Type

updatePolicy.type Update type

Most Disruptive Allowed Action

updatePolicy.mostDisruptiveAllowedAction Most disruptive allowed action

Health Check Name

name Health checks overview

Health Check

Type

type Health check categories, protocols, and ports

Initial Delay Seconds

autoHealingPolicies[].initialDelaySec Configure an autohealing policy in a MIG

Check Interval Sec

checkIntervalSec Configure an autohealing policy in a MIG

Healthy Threshold

healthyThreshold Configure an autohealing policy in a MIG

Timeout Sec

timeoutSec What makes a good autohealing health check

Unhealthy Threshold

unhealthyThreshold Configure an autohealing policy in a MIG

Response

httpsHealthCheck.response Success criteria for HTTP, HTTPS, and HTTP/2

Proxy Header

httpsHealthCheck.proxyHeader Headers

Port

httpsHealthCheck.port Health check categories, protocols, and ports

Request

tcpHealthCheck.request Success criteria for HTTP, HTTPS, and HTTP/2

Request Path

httpsHealthCheck.requestPath Success criteria for HTTP, HTTPS, and HTTP/2

Host

httpsHealthCheck.host Headers

Enable Logging

logConfig.enable Health check logging information

Autoscaler Name

name

If empty, the name is derived from hostname.

Autoscaling Enabled

Create an autoscaler for the MIG

Autoscaling groups of instances

Cooldown Period

autoscalingPolicy.coolDownPeriodSec Initialization period

Autoscaling CPU

Target

autoscalingPolicy.cpuUtilization.utilizationTarget Scaling based on CPU utilization

Predictive Method

autoscalingPolicy.cpuUtilization.predictiveMethod Predictive autoscaling

Autoscaling Metric

Name

name Autoscale to maintain a metric at a target value

Target

autoscalingPolicy.customMetricUtilizations[].utilizationTarget Autoscale to maintain a metric at a target value

Type

autoscalingPolicy.customMetricUtilizations[].utilizationTargetType Autoscale to maintain a metric at a target value

Scaling Schedules

Disabled

autoscalingPolicy.scalingSchedules[].disabled Scaling based on schedules

Duration Sec

autoscalingPolicy.scalingSchedules[].durationSec Scaling schedule settings

Min Required Replicas

autoscalingPolicy.scalingSchedules[].minRequiredReplicas Scaling schedule settings

Name

Creating a schaling schedule

Schedule

autoscalingPolicy.scalingSchedules[].schedule Scaling schedule settings

Time Zone

autoscalingPolicy.scalingSchedules[].timeZone Scaling schedule settings

Autoscaling Scale in Control

Fixed Replicas

autoscalingPolicy.scaleInControl.maxScaledInReplicas.fixed Configure scale-in controls

Percent Replicas

autoscalingPolicy.scaleInControl.maxScaledInReplicas.percent Configure scale-in controls

Time Window Sec

autoscalingPolicy.scaleInControl.timeWindowSec Configure scale-in controls

Named Ports

Name

namedPorts[].name Named ports

Port

namedPorts[].port Named ports

Wait for Instances

Whether to wait for all instances to be created/updated before returning. If set to true, when the operation fails, Terraform continues trying until the timeout is reached.

MIG Timeouts

Create

Timeout for Terraform instance creation.

Update

Timeout for Terraform instance update.

Delete

Timeout for Terraform instance deletion.

Labels

Key

allInstancesConfig.properties.labels Organize resources using labels

Value

allInstancesConfig.properties.labels Organize resources using labels