Skip to content

Creates a capacity provider that manages compute resources for Lambda functions

Description

Creates a capacity provider that manages compute resources for Lambda functions

Usage

lambda_create_capacity_provider(CapacityProviderName, VpcConfig,
  PermissionsConfig, InstanceRequirements, CapacityProviderScalingConfig,
  KmsKeyArn, Tags, PropagateTags, TelemetryConfig)

Arguments

  • CapacityProviderName

[required] The name of the capacity provider.

  • VpcConfig

[required] The VPC configuration for the capacity provider, including subnet IDs and security group IDs where compute instances will be launched.

  • PermissionsConfig

[required] The permissions configuration that specifies the IAM role ARN used by the capacity provider to manage compute resources.

  • InstanceRequirements

The instance requirements that specify the compute instance characteristics, including architectures and allowed or excluded instance types.

  • CapacityProviderScalingConfig

The scaling configuration that defines how the capacity provider scales compute instances, including maximum vCPU count and scaling policies.

  • KmsKeyArn

The ARN of the KMS key used to encrypt data associated with the capacity provider.

  • Tags

A list of tags to associate with the capacity provider.

  • PropagateTags

The tag propagation configuration for the capacity provider. Specifies tags to apply to managed resources at launch.

  • TelemetryConfig

The telemetry configuration for the capacity provider. Specifies logging settings for managed resources.

Value

A list with the following syntax:

list(
  CapacityProvider = list(
    CapacityProviderArn = "string",
    State = "Pending"|"Active"|"Failed"|"Deleting",
    VpcConfig = list(
      SubnetIds = list(
        "string"
      ),
      SecurityGroupIds = list(
        "string"
      )
    ),
    PermissionsConfig = list(
      CapacityProviderOperatorRoleArn = "string"
    ),
    InstanceRequirements = list(
      Architectures = list(
        "x86_64"|"arm64"
      ),
      AllowedInstanceTypes = list(
        "string"
      ),
      ExcludedInstanceTypes = list(
        "string"
      )
    ),
    CapacityProviderScalingConfig = list(
      MaxVCpuCount = 123,
      ScalingMode = "Auto"|"Manual",
      ScalingPolicies = list(
        list(
          PredefinedMetricType = "LambdaCapacityProviderAverageCPUUtilization",
          TargetValue = 123.0
        )
      )
    ),
    KmsKeyArn = "string",
    LastModified = "string",
    PropagateTags = list(
      Mode = "None"|"Explicit",
      ExplicitTags = list(
        "string"
      )
    ),
    TelemetryConfig = list(
      LoggingConfig = list(
        SystemLogLevel = "DEBUG"|"INFO"|"WARN",
        LogGroup = "string"
      )
    )
  )
)

Request syntax

svc$create_capacity_provider(
  CapacityProviderName = "string",
  VpcConfig = list(
    SubnetIds = list(
      "string"
    ),
    SecurityGroupIds = list(
      "string"
    )
  ),
  PermissionsConfig = list(
    CapacityProviderOperatorRoleArn = "string"
  ),
  InstanceRequirements = list(
    Architectures = list(
      "x86_64"|"arm64"
    ),
    AllowedInstanceTypes = list(
      "string"
    ),
    ExcludedInstanceTypes = list(
      "string"
    )
  ),
  CapacityProviderScalingConfig = list(
    MaxVCpuCount = 123,
    ScalingMode = "Auto"|"Manual",
    ScalingPolicies = list(
      list(
        PredefinedMetricType = "LambdaCapacityProviderAverageCPUUtilization",
        TargetValue = 123.0
      )
    )
  ),
  KmsKeyArn = "string",
  Tags = list(
    "string"
  ),
  PropagateTags = list(
    Mode = "None"|"Explicit",
    ExplicitTags = list(
      "string"
    )
  ),
  TelemetryConfig = list(
    LoggingConfig = list(
      SystemLogLevel = "DEBUG"|"INFO"|"WARN",
      LogGroup = "string"
    )
  )
)