Skip to content

Commit 8827950

Browse files
jsoucheironclaude
andcommitted
Add missing fields to existing pycfmodel resources
Updated the following resources with fields that were added to the AWS CloudFormation schemas since the models were originally created: - IAMUser: Added Tags field - KMSKey: Added RotationPeriodInDays field - S3Bucket: Added AbacStatus, MetadataConfiguration, MetadataTableConfiguration - OpenSearchDomain: Added AIMLOptions, IPAddressType, IdentityCenterOptions, OffPeakWindowOptions, SkipShardMigrationWait, SoftwareUpdateOptions - EC2VPCEndpoint: Added DnsOptions, IpAddressType, ResourceConfigurationArn, ServiceNetworkArn, ServiceRegion, Tags Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 814d5b4 commit 8827950

File tree

5 files changed

+37
-1
lines changed

5 files changed

+37
-1
lines changed

pycfmodel/model/resources/ec2_vpc_endpoint_policy.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
from typing import List, Literal, Optional
22

33
from pycfmodel.model.base import CustomModel
4+
from pycfmodel.model.generic import ResolvableGeneric
45
from pycfmodel.model.resources.properties.policy_document import PolicyDocument as resource_policy_document
56
from pycfmodel.model.resources.resource import Resource
67
from pycfmodel.model.types import Resolvable, ResolvableBool, ResolvableStr
@@ -11,24 +12,36 @@ class EC2VpcEndpointPolicyProperties(CustomModel):
1112
"""
1213
Properties:
1314
15+
- DnsOptions: DNS options for the endpoint.
16+
- IpAddressType: The supported IP address types.
1417
- PolicyDocument: A [policy document][pycfmodel.model.resources.properties.policy_document.PolicyDocument] object.
1518
- PrivateDnsEnabled: Indicate whether to associate a private hosted zone with the specified VPC.
19+
- ResourceConfigurationArn: The Amazon Resource Name (ARN) of the resource configuration.
1620
- RouteTableIds: One or more route table IDs.
1721
- SecurityGroupIds: The ID of one or more security groups to associate with the endpoint network interface.
1822
- ServiceName: The service name.
23+
- ServiceNetworkArn: The Amazon Resource Name (ARN) of the service network.
24+
- ServiceRegion: The region of the service.
1925
- SubnetIds: The ID of one or more subnets in which to create an endpoint network interface.
26+
- Tags: The tags to associate with the endpoint.
2027
- VpcEndpointType: The type of endpoint.
2128
- VpcId: The ID of the VPC in which the endpoint will be used.
2229
2330
More info at [AWS Docs](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ec2-vpcendpoint.html)
2431
"""
2532

33+
DnsOptions: Optional[ResolvableGeneric] = None
34+
IpAddressType: Optional[ResolvableStr] = None
2635
PolicyDocument: Optional[Resolvable[resource_policy_document]] = None
2736
PrivateDnsEnabled: Optional[ResolvableBool] = None
37+
ResourceConfigurationArn: Optional[ResolvableStr] = None
2838
RouteTableIds: Optional[Resolvable[List[ResolvableStr]]] = None
2939
SecurityGroupIds: Optional[Resolvable[List[ResolvableStr]]] = None
3040
ServiceName: ResolvableStr
41+
ServiceNetworkArn: Optional[ResolvableStr] = None
42+
ServiceRegion: Optional[ResolvableStr] = None
3143
SubnetIds: Optional[Resolvable[List[ResolvableStr]]] = None
44+
Tags: Optional[Resolvable[List[ResolvableGeneric]]] = None
3245
VpcEndpointType: Optional[ResolvableStr] = None
3346
VpcId: ResolvableStr
3447

pycfmodel/model/resources/iam_user.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
from typing import Dict, List, Literal, Optional
22

33
from pycfmodel.model.base import CustomModel
4+
from pycfmodel.model.generic import ResolvableGeneric
45
from pycfmodel.model.parameter import Parameter
56
from pycfmodel.model.resources.properties.policy import Policy
67
from pycfmodel.model.resources.resource import Resource
@@ -18,6 +19,7 @@ class IAMUserProperties(CustomModel):
1819
- Path: Path to the user.
1920
- PermissionsBoundary: ARN of the policy used to set the permissions boundary.
2021
- Policies: A list of [policy][pycfmodel.model.resources.properties.policy.Policy] objects.
22+
- Tags: A list of tags to attach to the new user.
2123
- UserName: Name of the user.
2224
2325
More info at [AWS Docs](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-iam-user.html)
@@ -29,6 +31,7 @@ class IAMUserProperties(CustomModel):
2931
Path: Optional[ResolvableStr] = None
3032
PermissionsBoundary: Optional[ResolvableStr] = None
3133
Policies: Optional[Resolvable[List[Resolvable[Policy]]]] = None
34+
Tags: Optional[Resolvable[List[ResolvableGeneric]]] = None
3235
UserName: Optional[ResolvableStr] = None
3336

3437

pycfmodel/model/resources/kms_key.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ class KMSKeyProperties(CustomModel):
1919
- KeySpec: Specifies the type of CMK to create.
2020
- MultiRegion: Allows multi-Region primary CMK to be replicated in other AWS Regions.
2121
- PendingWindowInDays: Number of days in the waiting period before AWS KMS deletes a CMK that has been removed from a CloudFormation stack.
22+
- RotationPeriodInDays: Custom period of time between each rotation date.
2223
- Tags: Array of key-value pairs.
2324
2425
More info at [AWS Docs](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-kms-key.html)
@@ -34,6 +35,7 @@ class KMSKeyProperties(CustomModel):
3435
MultiRegion: Optional[ResolvableBool] = None
3536
Origin: Optional[ResolvableStr] = None
3637
PendingWindowInDays: Optional[ResolvableInt] = None
38+
RotationPeriodInDays: Optional[ResolvableInt] = None
3739
Tags: Optional[Resolvable[List[Tag]]] = None
3840

3941

pycfmodel/model/resources/opensearch_domain.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
from pycfmodel.model.resources.properties.policy_document import PolicyDocument
66
from pycfmodel.model.resources.properties.tag import Tag
77
from pycfmodel.model.resources.resource import Resource
8-
from pycfmodel.model.types import Resolvable, ResolvableStr
8+
from pycfmodel.model.types import Resolvable, ResolvableBool, ResolvableStr
99

1010

1111
class OpenSearchDomainProperties(CustomModel):
@@ -15,16 +15,22 @@ class OpenSearchDomainProperties(CustomModel):
1515
- AccessPolicies: A [policy document][pycfmodel.model.resources.properties.policy_document.PolicyDocument] object.
1616
- AdvancedOptions: Additional options to specify for the OpenSearch Service domain.
1717
- AdvancedSecurityOptions: Specifies options for fine-grained access control.
18+
- AIMLOptions: Machine learning options for the domain.
1819
- ClusterConfig: ClusterConfig is a property of the AWS::OpenSearchService::Domain resource that configures an Amazon OpenSearch Service cluster.
1920
- CognitoOptions: Configures OpenSearch Service to use Amazon Cognito authentication for OpenSearch Dashboards.
2021
- DomainEndpointOptions: Specifies additional options for the domain endpoint, such as whether to require HTTPS for all traffic or whether to use a custom endpoint rather than the default endpoint.
2122
- DomainName: A name for the OpenSearch Service domain.
2223
- EBSOptions: The configurations of Amazon Elastic Block Store (Amazon EBS) volumes that are attached to data nodes in the OpenSearch Service domain.
2324
- EncryptionAtRestOptions: Whether the domain should encrypt data at rest, and if so, the AWS Key Management Service key to use.
2425
- EngineVersion: The version of OpenSearch to use. The value must be in the format OpenSearch_X.Y or Elasticsearch_X.Y. If not specified, the latest version of OpenSearch is used.
26+
- IdentityCenterOptions: Identity Center options for the domain.
27+
- IPAddressType: The IP address type for the domain.
2528
- LogPublishingOptions: An object with one or more of the following keys: SEARCH_SLOW_LOGS, ES_APPLICATION_LOGS, INDEX_SLOW_LOGS, AUDIT_LOGS, depending on the types of logs you want to publish. Each key needs a valid LogPublishingOption value.
2629
- NodeToNodeEncryptionOptions: Specifies whether node-to-node encryption is enabled.
30+
- OffPeakWindowOptions: Off-peak window options for the domain.
31+
- SkipShardMigrationWait: Whether to skip the shard migration wait.
2732
- SnapshotOptions: DEPRECATED. The automated snapshot configuration for the OpenSearch Service domain indices.
33+
- SoftwareUpdateOptions: Software update options for the domain.
2834
- Tags: An arbitrary set of tags (key–value pairs) to associate with the OpenSearch Service domain.
2935
- VPCOptions: The virtual private cloud (VPC) configuration for the OpenSearch Service domain.
3036
@@ -34,16 +40,22 @@ class OpenSearchDomainProperties(CustomModel):
3440
AccessPolicies: Optional[Resolvable[PolicyDocument]] = None
3541
AdvancedOptions: Optional[ResolvableGeneric] = None
3642
AdvancedSecurityOptions: Optional[ResolvableGeneric] = None
43+
AIMLOptions: Optional[ResolvableGeneric] = None
3744
ClusterConfig: Optional[ResolvableGeneric] = None
3845
CognitoOptions: Optional[ResolvableGeneric] = None
3946
DomainEndpointOptions: Optional[ResolvableGeneric] = None
4047
DomainName: Optional[ResolvableStr] = None
4148
EBSOptions: Optional[ResolvableGeneric] = None
4249
EncryptionAtRestOptions: Optional[ResolvableGeneric] = None
4350
EngineVersion: Optional[ResolvableStr] = None
51+
IdentityCenterOptions: Optional[ResolvableGeneric] = None
52+
IPAddressType: Optional[ResolvableStr] = None
4453
LogPublishingOptions: Optional[ResolvableGeneric] = None
4554
NodeToNodeEncryptionOptions: Optional[ResolvableGeneric] = None
55+
OffPeakWindowOptions: Optional[ResolvableGeneric] = None
56+
SkipShardMigrationWait: Optional[ResolvableBool] = None
4657
SnapshotOptions: Optional[ResolvableGeneric] = None
58+
SoftwareUpdateOptions: Optional[ResolvableGeneric] = None
4759
Tags: Optional[Resolvable[List[Tag]]] = None
4860
VPCOptions: Optional[ResolvableGeneric] = None
4961

pycfmodel/model/resources/s3_bucket.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ class S3BucketProperties(CustomModel):
1111
"""
1212
Properties:
1313
14+
- AbacStatus: The ABAC status of the general purpose bucket.
1415
- AccelerateConfiguration: Configures the transfer acceleration state for an Amazon S3 bucket.
1516
- AccessControl: A canned access control list (ACL) that grants predefined permissions to the bucket.
1617
- AnalyticsConfigurations: Specifies the configuration and any analyses for the analytics filter of an Amazon S3 bucket.
@@ -21,6 +22,8 @@ class S3BucketProperties(CustomModel):
2122
- InventoryConfigurations: Specifies the inventory configuration for an Amazon S3 bucket.
2223
- LifecycleConfiguration: Specifies the lifecycle configuration for objects in an Amazon S3 bucket.
2324
- LoggingConfiguration: Settings that define where logs are stored.
25+
- MetadataConfiguration: The S3 Metadata configuration for a general purpose bucket.
26+
- MetadataTableConfiguration: The metadata table configuration of an S3 general purpose bucket.
2427
- MetricsConfigurations: Specifies a metrics configuration for the CloudWatch request metrics.
2528
- NotificationConfiguration: Defines how Amazon S3 handles bucket notifications.
2629
- ObjectLockConfiguration: Places an Object Lock configuration on the specified bucket.
@@ -35,6 +38,7 @@ class S3BucketProperties(CustomModel):
3538
More info at [AWS Docs](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-s3-bucket.html)
3639
"""
3740

41+
AbacStatus: Optional[ResolvableStr] = None
3842
AccelerateConfiguration: Optional[ResolvableGeneric] = None
3943
AccessControl: Optional[ResolvableStr] = None
4044
AnalyticsConfigurations: Optional[Resolvable[List[ResolvableGeneric]]] = None
@@ -45,6 +49,8 @@ class S3BucketProperties(CustomModel):
4549
InventoryConfigurations: Optional[Resolvable[List[ResolvableGeneric]]] = None
4650
LifecycleConfiguration: Optional[ResolvableGeneric] = None
4751
LoggingConfiguration: Optional[ResolvableGeneric] = None
52+
MetadataConfiguration: Optional[ResolvableGeneric] = None
53+
MetadataTableConfiguration: Optional[ResolvableGeneric] = None
4854
MetricsConfigurations: Optional[Resolvable[List[ResolvableGeneric]]] = None
4955
NotificationConfiguration: Optional[ResolvableGeneric] = None
5056
ObjectLockConfiguration: Optional[ResolvableGeneric] = None

0 commit comments

Comments
 (0)