Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,21 +24,21 @@

class VpcConfig(BaseModel):
# Optional list of security group IDs - supports intrinsic functions for dynamic references
SecurityGroupIds: Optional[List[SamIntrinsicable[str]]] = vpcconfig("SecurityGroupIds")
SecurityGroupIds: Optional[SamIntrinsicable[List[SamIntrinsicable[str]]]] = vpcconfig("SecurityGroupIds")
# Required list of subnet IDs - supports intrinsic functions for dynamic VPC configuration
SubnetIds: List[SamIntrinsicable[str]] = vpcconfig("SubnetIds")
SubnetIds: SamIntrinsicable[List[SamIntrinsicable[str]]] = vpcconfig("SubnetIds")


class InstanceRequirements(BaseModel):
# Optional list of CPU architectures - maps to CFN InstanceRequirements.Architecture
# Uses List[SamIntrinsicable[str]] to support intrinsic functions like !Ref for dynamic architecture values
Architectures: Optional[List[SamIntrinsicable[str]]] = instancerequirements("Architectures")
# Uses SamIntrinsicable[List[SamIntrinsicable[str]]] to support intrinsic functions like !Ref for both list and list item
Architectures: Optional[SamIntrinsicable[List[SamIntrinsicable[str]]]] = instancerequirements("Architectures")
# Optional list of allowed EC2 instance types - maps to CFN InstanceRequirements.AllowedInstanceTypes
# Uses List[SamIntrinsicable[str]] to support intrinsic functions like !Ref for dynamic instance types
AllowedTypes: Optional[List[SamIntrinsicable[str]]] = instancerequirements("AllowedTypes")
# Uses SamIntrinsicable[List[SamIntrinsicable[str]]] to support intrinsic functions like !Ref for both list and list item
AllowedTypes: Optional[SamIntrinsicable[List[SamIntrinsicable[str]]]] = instancerequirements("AllowedTypes")
# Optional list of excluded EC2 instance types - maps to CFN InstanceRequirements.ExcludedInstanceTypes
# Uses List[SamIntrinsicable[str]] to support intrinsic functions like !Ref for dynamic instance types
ExcludedTypes: Optional[List[SamIntrinsicable[str]]] = instancerequirements("ExcludedTypes")
# Uses SamIntrinsicable[List[SamIntrinsicable[str]]] to support intrinsic functions like !Ref for both list and list item
ExcludedTypes: Optional[SamIntrinsicable[List[SamIntrinsicable[str]]]] = instancerequirements("ExcludedTypes")


class ScalingConfig(BaseModel):
Expand Down
145 changes: 90 additions & 55 deletions samtranslator/schema/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -275088,49 +275088,70 @@
"additionalProperties": false,
"properties": {
"AllowedTypes": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "The allowed instance types.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`AllowedInstanceTypes`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-instancerequirements.html#cfn-lambda-capacityprovider-instancerequirements-allowedinstancetypes) property of the `AWS::Lambda::CapacityProvider` `InstanceRequirements` data type.",
"title": "AllowedTypes",
"type": "array"
"title": "AllowedTypes"
},
"Architectures": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "The CPU architecture for the instances.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`Architecture`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-instancerequirements.html#cfn-lambda-capacityprovider-instancerequirements-architecture) property of the `AWS::Lambda::CapacityProvider` `InstanceRequirements` data type.",
"title": "Architectures",
"type": "array"
"title": "Architectures"
},
"ExcludedTypes": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "The excluded instance types.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`ExcludedInstanceTypes`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-instancerequirements.html#cfn-lambda-capacityprovider-instancerequirements-excludedinstancetypes) property of the `AWS::Lambda::CapacityProvider` `InstanceRequirements` data type.",
"title": "ExcludedTypes",
"type": "array"
"title": "ExcludedTypes"
}
},
"title": "InstanceRequirements",
Expand Down Expand Up @@ -277136,34 +277157,48 @@
"additionalProperties": false,
"properties": {
"SecurityGroupIds": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "A list of VPC security group IDs.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`SecurityGroupIds`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-vpcconfig.html#cfn-lambda-capacityprovider-vpcconfig-securitygroupids) property of the `AWS::Lambda::CapacityProvider` `VpcConfig` data type.",
"title": "SecurityGroupIds",
"type": "array"
"title": "SecurityGroupIds"
},
"SubnetIds": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "A list of VPC subnet IDs.\n*Type*: List of String\n*Required*: Yes\n*AWS CloudFormation compatibility*: This property is passed directly to the [`SubnetIds`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-vpcconfig.html#cfn-lambda-capacityprovider-vpcconfig-subnetids) property of the `AWS::Lambda::CapacityProvider` `VpcConfig` data type.",
"title": "SubnetIds",
"type": "array"
"title": "SubnetIds"
}
},
"required": [
Expand Down
145 changes: 90 additions & 55 deletions schema_source/sam.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1686,49 +1686,70 @@
"additionalProperties": false,
"properties": {
"AllowedTypes": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "The allowed instance types.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`AllowedInstanceTypes`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-instancerequirements.html#cfn-lambda-capacityprovider-instancerequirements-allowedinstancetypes) property of the `AWS::Lambda::CapacityProvider` `InstanceRequirements` data type.",
"title": "AllowedTypes",
"type": "array"
"title": "AllowedTypes"
},
"Architectures": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "The CPU architecture for the instances.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`Architecture`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-instancerequirements.html#cfn-lambda-capacityprovider-instancerequirements-architecture) property of the `AWS::Lambda::CapacityProvider` `InstanceRequirements` data type.",
"title": "Architectures",
"type": "array"
"title": "Architectures"
},
"ExcludedTypes": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "The excluded instance types.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`ExcludedInstanceTypes`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-instancerequirements.html#cfn-lambda-capacityprovider-instancerequirements-excludedinstancetypes) property of the `AWS::Lambda::CapacityProvider` `InstanceRequirements` data type.",
"title": "ExcludedTypes",
"type": "array"
"title": "ExcludedTypes"
}
},
"title": "InstanceRequirements",
Expand Down Expand Up @@ -3649,34 +3670,48 @@
"additionalProperties": false,
"properties": {
"SecurityGroupIds": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "A list of VPC security group IDs.\n*Type*: List of String\n*Required*: No\n*AWS CloudFormation compatibility*: This property is passed directly to the [`SecurityGroupIds`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-vpcconfig.html#cfn-lambda-capacityprovider-vpcconfig-securitygroupids) property of the `AWS::Lambda::CapacityProvider` `VpcConfig` data type.",
"title": "SecurityGroupIds",
"type": "array"
"title": "SecurityGroupIds"
},
"SubnetIds": {
"items": {
"anyOf": [
{
"type": "string"
"anyOf": [
{
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
}
]
},
{
"type": "object"
}
]
},
"type": "array"
}
],
"markdownDescription": "A list of VPC subnet IDs.\n*Type*: List of String\n*Required*: Yes\n*AWS CloudFormation compatibility*: This property is passed directly to the [`SubnetIds`](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-capacityprovider-vpcconfig.html#cfn-lambda-capacityprovider-vpcconfig-subnetids) property of the `AWS::Lambda::CapacityProvider` `VpcConfig` data type.",
"title": "SubnetIds",
"type": "array"
"title": "SubnetIds"
}
},
"required": [
Expand Down
Loading
Loading