> For the complete documentation index, see [llms.txt](https://docs.mechcloud.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mechcloud.io/cloud-computing/stateless-iac/aws/examples-resources-with-cost/lambda/lambda-managed-instances.md).

# Lambda Managed Instances

### Docs

* <https://docs.aws.amazon.com/lambda/latest/dg/lambda-managed-instances.html>

### Creating a lambda capacity provider with minimal parameters

```
resources:
  - type: aws_lambda_capacity_provider
    name: my-capacity-provider
    props:
      permissions_config:
        capacity_provider_operator_role_arn: arn:aws:iam::123456789012:role/LambdaCapacityProviderRole
      vpc_config:
        subnet_ids:
          - subnet-12345678
        security_group_ids:
          - sg-12345678
      instance_requirements:
        architectures:
          - arm64
        allowed_instance_types:
          - m6g.large
          - m6g.2xlarge
```

#### Example price for above configuration

```
my-capacity-provider (action: create)
=> Price (EC2 Instance cost (m6g.2xlarge) - price: $0.308/Hrs, monthly: $229.15)
=> Price (Management fee (m6g.2xlarge) - price: $0.0462/Hrs, monthly: $34.37)
```
