Reference for the teleport_health_check_config Terraform resource
This page describes the supported values of the teleport_health_check_config resource of the Teleport Terraform provider.
Example Usage
resource "teleport_health_check_config" "example" {
metadata = {
name = "example"
description = "Example health check config"
labels = {
foo = "bar"
}
}
version = "v1"
spec = {
interval = "60s"
timeout = "5s"
healthy_threshold = 3
unhealthy_threshold = 2
match = {
db_labels = [{
name = "env"
values = [
"foo",
"bar",
]
}]
db_labels_expression = "labels.foo == `bar`"
}
}
}
Schema
Required
metadata
(Attributes) Metadata is the health check config resource's metadata. (see below for nested schema)spec
(Attributes) Spec is the health check config specification. (see below for nested schema)version
(String) Version is the health check config version.
Optional
sub_kind
(String) SubKind is an optional resource sub kind.
Nested Schema for metadata
Required:
name
(String) name is an object name.
Optional:
description
(String) description is object description.expires
(String) expires is a global expiry time header can be set on any resource in the system.labels
(Map of String) labels is a set of labels.
Nested Schema for spec
Required:
match
(Attributes) Match is used to select resources that these settings apply to. (see below for nested schema)
Optional:
healthy_threshold
(Number) HealthyThreshold is the number of consecutive passing health checks after which a target's health status becomes "healthy".interval
(String) Interval is the time between each health check.timeout
(String) Timeout is the health check connection establishment timeout. An attempt that times out is a failed attempt.unhealthy_threshold
(Number) UnhealthyThreshold is the number of consecutive failing health checks after which a target's health status becomes "unhealthy".
Nested Schema for spec.match
Optional:
db_labels
(Attributes List) DBLabels matches database labels. An empty value is ignored. The match result is logically ANDed with DBLabelsExpression, if both are non-empty. (see below for nested schema)db_labels_expression
(String) DBLabelsExpression is a label predicate expression to match databases. An empty value is ignored. The match result is logically ANDed with DBLabels, if both are non-empty.
Nested Schema for spec.match.db_labels
Optional:
name
(String) The name of the label.values
(List of String) The values associated with the label.