TargetGroup
A resource of the AWS provider, version 0.3.0, in its Load Balancing group. Import it with:
import TargetGroup from "aws/loadbalancing"Example
resource TargetGroup example {
name = "example-value"
port = 3.14
protocol = "HTTP"
protocolVersion = "HTTP1"
vpcId = "example-value"
targetType = "instance"
ipAddressType = "ipv4"
healthCheck = "..."
deregistrationDelay = 300
slowStart = 0
stickiness = "..."
targets = "..."
tags = "..."
}Properties
Set by your code in the resource block. A required one must be set; any other you leave out takes the value under Default, if it has one.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
name | string | — | No | The name of the target group |
port | number | — | No | The port on which targets receive traffic |
protocol | string | "HTTP" | No | The protocol for routing traffic Allowed: "HTTP", "HTTPS", "TCP", "TLS", "UDP", "TCP_UDP", "GENEVE" |
protocolVersion | string | "HTTP1" | No | The protocol version (ALB only) Allowed: "HTTP1", "HTTP2", "GRPC" |
vpcId | string | — | No | The VPC ID for the target group |
targetType | string | "instance" | No | The target type Allowed: "instance", "ip", "lambda", "alb" |
ipAddressType | string | "ipv4" | No | The IP address type Allowed: "ipv4", "ipv6" |
healthCheck | any | — | No | Health check configuration |
deregistrationDelay | number | 300 | No | Deregistration delay in seconds |
slowStart | number | 0 | No | Slow start duration in seconds (ALB only) |
stickiness | any | — | No | Stickiness configuration |
targets | any[] | — | No | Target IDs to register (instance IDs or IP addresses) |
tags | object | — | No | Tags to apply to the target group |
Set by AWS after the resource is created: your code can read them but not set them. An importable one identifies an existing resource.
| Name | Type | Importable | Description |
|---|---|---|---|
arn | string | Yes | The Amazon Resource Name (ARN) of the target group |
loadBalancerArns | any[] | No | The load balancer ARNs attached to this target group |