Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expand docs for auto_healing_policies for Instance Group Managers #612

Merged
merged 1 commit into from
Oct 26, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 21 additions & 3 deletions website/docs/r/compute_instance_group_manager.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,21 @@ and [API](https://cloud.google.com/compute/docs/reference/latest/instanceGroupMa
## Example Usage

```hcl
resource "google_compute_health_check" "autohealing" {
name = "autohealing-health-check"
check_interval_sec = 5
timeout_sec = 5
healthy_threshold = 2
unhealthy_threshold = 10 # 50 seconds

http_health_check {
request_path = "/healthz"
port = "8080"
}
}

resource "google_compute_instance_group_manager" "appserver" {
name = "appserver-igm"
name = "appserver-igm"

base_instance_name = "app"
instance_template = "${google_compute_instance_template.appserver.self_link}"
Expand All @@ -33,6 +46,11 @@ resource "google_compute_instance_group_manager" "appserver" {
name = "customHTTP"
port = 8888
}

auto_healing_policies {
health_check = "${google_compute_health_check.autohealing.self_link}"
initial_delay_sec = 300
}
}
```

Expand Down Expand Up @@ -86,7 +104,7 @@ The following arguments are supported:
---

* `auto_healing_policies` - (Optional, [Beta](/docs/providers/google/index.html#beta-features)) The autohealing policies for this managed instance
group. You can specify only one value. Structure is documented below.
group. You can specify only one value. Structure is documented below. For more information, see the [official documentation](https://cloud.google.com/compute/docs/instance-groups/creating-groups-of-managed-instances#monitoring_groups).

The `named_port` block supports: (Include a `named_port` block for each named-port required).

Expand All @@ -96,7 +114,7 @@ The `named_port` block supports: (Include a `named_port` block for each named-po

The `auto_healing_policies` block supports:

* `health_check` - (Required) The health check that signals autohealing.
* `health_check` - (Required) The health check resource that signals autohealing.

* `initial_delay_sec` - (Required) The number of seconds that the managed instance group waits before
it applies autohealing policies to new instances or recently recreated instances. Between 0 and 3600.
Expand Down
25 changes: 22 additions & 3 deletions website/docs/r/compute_region_instance_group_manager.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,21 @@ and [API](https://cloud.google.com/compute/docs/reference/latest/regionInstanceG
## Example Usage

```hcl
resource "google_compute_health_check" "autohealing" {
name = "autohealing-health-check"
check_interval_sec = 5
timeout_sec = 5
healthy_threshold = 2
unhealthy_threshold = 10 # 50 seconds

http_health_check {
request_path = "/healthz"
port = "8080"
}
}

resource "google_compute_region_instance_group_manager" "appserver" {
name = "appserver-igm"
name = "appserver-igm"

base_instance_name = "app"
instance_template = "${google_compute_instance_template.appserver.self_link}"
Expand All @@ -32,7 +45,13 @@ resource "google_compute_region_instance_group_manager" "appserver" {
name = "custom"
port = 8888
}

auto_healing_policies {
health_check = "${google_compute_health_check.autohealing.self_link}"
initial_delay_sec = 300
}
}

```

## Argument Reference
Expand Down Expand Up @@ -78,7 +97,7 @@ The following arguments are supported:
---

* `auto_healing_policies` - (Optional, [Beta](/docs/providers/google/index.html#beta-features)) The autohealing policies for this managed instance
group. You can specify only one value. Structure is documented below.
group. You can specify only one value. Structure is documented below. For more information, see the [official documentation](https://cloud.google.com/compute/docs/instance-groups/creating-groups-of-managed-instances#monitoring_groups).

The `named_port` block supports: (Include a `named_port` block for each named-port required).

Expand All @@ -88,7 +107,7 @@ The `named_port` block supports: (Include a `named_port` block for each named-po

The `auto_healing_policies` block supports:

* `health_check` - (Required) The health check that signals autohealing.
* `health_check` - (Required) The health check resource that signals autohealing.

* `initial_delay_sec` - (Required) The number of seconds that the managed instance group waits before
it applies autohealing policies to new instances or recently recreated instances. Between 0 and 3600.
Expand Down