Skip to content

Create Target Group

vpclattice_create_target_group R Documentation

Creates a target group

Description

Creates a target group. A target group is a collection of targets, or compute resources, that run your application or service. A target group can only be used by a single service.

For more information, see Target groups in the Amazon VPC Lattice User Guide.

Usage

vpclattice_create_target_group(name, type, config, clientToken, tags)

Arguments

name

[required] The name of the target group. The name must be unique within the account. The valid characters are a-z, 0-9, and hyphens (-). You can't use a hyphen as the first or last character, or immediately after another hyphen.

type

[required] The type of target group.

config

The target group configuration.

clientToken

A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If you retry a request that completed successfully using the same client token and parameters, the retry succeeds without performing any actions. If the parameters aren't identical, the retry fails.

tags

The tags for the target group.

Value

A list with the following syntax:

list(
  id = "string",
  arn = "string",
  name = "string",
  type = "IP"|"LAMBDA"|"INSTANCE"|"ALB",
  config = list(
    port = 123,
    protocol = "HTTP"|"HTTPS"|"TCP",
    protocolVersion = "HTTP1"|"HTTP2"|"GRPC",
    ipAddressType = "IPV4"|"IPV6",
    vpcIdentifier = "string",
    healthCheck = list(
      enabled = TRUE|FALSE,
      protocol = "HTTP"|"HTTPS"|"TCP",
      protocolVersion = "HTTP1"|"HTTP2",
      port = 123,
      path = "string",
      healthCheckIntervalSeconds = 123,
      healthCheckTimeoutSeconds = 123,
      healthyThresholdCount = 123,
      unhealthyThresholdCount = 123,
      matcher = list(
        httpCode = "string"
      )
    ),
    lambdaEventStructureVersion = "V1"|"V2"
  ),
  status = "CREATE_IN_PROGRESS"|"ACTIVE"|"DELETE_IN_PROGRESS"|"CREATE_FAILED"|"DELETE_FAILED"
)

Request syntax

svc$create_target_group(
  name = "string",
  type = "IP"|"LAMBDA"|"INSTANCE"|"ALB",
  config = list(
    port = 123,
    protocol = "HTTP"|"HTTPS"|"TCP",
    protocolVersion = "HTTP1"|"HTTP2"|"GRPC",
    ipAddressType = "IPV4"|"IPV6",
    vpcIdentifier = "string",
    healthCheck = list(
      enabled = TRUE|FALSE,
      protocol = "HTTP"|"HTTPS"|"TCP",
      protocolVersion = "HTTP1"|"HTTP2",
      port = 123,
      path = "string",
      healthCheckIntervalSeconds = 123,
      healthCheckTimeoutSeconds = 123,
      healthyThresholdCount = 123,
      unhealthyThresholdCount = 123,
      matcher = list(
        httpCode = "string"
      )
    ),
    lambdaEventStructureVersion = "V1"|"V2"
  ),
  clientToken = "string",
  tags = list(
    "string"
  )
)