cdk-factory 0.17.3__py3-none-any.whl → 0.17.4__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -136,13 +136,10 @@ class VPCProviderMixin:
136
136
  "availability_zones": availability_zones,
137
137
  }
138
138
 
139
- # If we have subnet_ids from SSM, use the actual subnet IDs
139
+ # If we have subnet_ids from SSM, add them to the attributes
140
140
  if subnet_ids:
141
141
  # Use the actual subnet IDs from SSM
142
142
  vpc_attrs["public_subnet_ids"] = subnet_ids
143
- else:
144
- # Fallback to dummy subnets if no valid subnet IDs
145
- vpc_attrs["public_subnet_ids"] = ["subnet-dummy1", "subnet-dummy2"]
146
143
 
147
144
  # Use from_vpc_attributes() for SSM tokens with unique construct name
148
145
  self._vpc = ec2.Vpc.from_vpc_attributes(self, f"{self.stack_name}-VPC", **vpc_attrs)
@@ -111,6 +111,23 @@ class VpcStack(IStack, StandardizedSsmMixin):
111
111
  # Configure NAT gateways
112
112
  nat_gateway_count = self.vpc_config.nat_gateways.get("count", 1)
113
113
 
114
+ # Get explicit availability zones to avoid dummy AZs in pipeline synthesis
115
+ # When CDK synthesizes in a pipeline context, it doesn't have access to real AZs
116
+ # So we explicitly specify them based on the deployment region
117
+ availability_zones = None
118
+ if self.deployment:
119
+ region = self.deployment.region or "us-east-1"
120
+ # Explicitly list AZs for the region to avoid dummy values
121
+ max_azs = self.vpc_config.max_azs or 2
122
+ if region == "us-east-1":
123
+ availability_zones = ["us-east-1a", "us-east-1b", "us-east-1c"][:max_azs]
124
+ elif region == "us-east-2":
125
+ availability_zones = ["us-east-2a", "us-east-2b", "us-east-2c"][:max_azs]
126
+ elif region == "us-west-1":
127
+ availability_zones = ["us-west-1a", "us-west-1c"][:max_azs]
128
+ elif region == "us-west-2":
129
+ availability_zones = ["us-west-2a", "us-west-2b", "us-west-2c"][:max_azs]
130
+
114
131
  # Build VPC properties
115
132
  vpc_props = {
116
133
  "vpc_name": vpc_name,
@@ -119,7 +136,8 @@ class VpcStack(IStack, StandardizedSsmMixin):
119
136
  "subnet_configuration": subnet_configuration,
120
137
  "enable_dns_hostnames": self.vpc_config.enable_dns_hostnames,
121
138
  "enable_dns_support": self.vpc_config.enable_dns_support,
122
- "max_azs": self.vpc_config.max_azs, # Use max_azs instead of explicit availability_zones
139
+ "max_azs": self.vpc_config.max_azs if not availability_zones else None,
140
+ "availability_zones": availability_zones, # Use explicit AZs when available
123
141
  "gateway_endpoints": (
124
142
  {
125
143
  "S3": ec2.GatewayVpcEndpointOptions(
cdk_factory/version.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.17.3"
1
+ __version__ = "0.17.4"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cdk_factory
3
- Version: 0.17.3
3
+ Version: 0.17.4
4
4
  Summary: CDK Factory. A QuickStarter and best practices setup for CDK projects
5
5
  Author-email: Eric Wilson <eric.wilson@geekcafe.com>
6
6
  License: MIT License
@@ -2,7 +2,7 @@ cdk_factory/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
2
  cdk_factory/app.py,sha256=RnX0-pwdTAPAdKJK_j13Zl8anf9zYKBwboR0KA8K8xM,10346
3
3
  cdk_factory/cdk.json,sha256=SKZKhJ2PBpFH78j-F8S3VDYW-lf76--Q2I3ON-ZIQfw,3106
4
4
  cdk_factory/cli.py,sha256=FGbCTS5dYCNsfp-etshzvFlGDCjC28r6rtzYbe7KoHI,6407
5
- cdk_factory/version.py,sha256=EeS9PekXNgzjvO0Cb50iNEGmbKhvoH8cFB_Sc6cUoRU,23
5
+ cdk_factory/version.py,sha256=LisYi6U4jD61j06adgCNdZJfR0RhF_Im0hPrka6lSjc,23
6
6
  cdk_factory/builds/README.md,sha256=9BBWd7bXpyKdMU_g2UljhQwrC9i5O_Tvkb6oPvndoZk,90
7
7
  cdk_factory/commands/command_loader.py,sha256=QbLquuP_AdxtlxlDy-2IWCQ6D-7qa58aphnDPtp_uTs,3744
8
8
  cdk_factory/configurations/base_config.py,sha256=eJ3Pl3GWk1jVr_bYQaaWlw4_-ZiFGaiXllI_fOOX1i0,9323
@@ -67,7 +67,7 @@ cdk_factory/interfaces/istack.py,sha256=3xqGw5kNTt_KeLHdMxI7rIR0YORqcWQOqsacmDlT
67
67
  cdk_factory/interfaces/live_ssm_resolver.py,sha256=3FIr9a02SXqZmbFs3RT0WxczWEQR_CF7QSt7kWbDrVE,8163
68
68
  cdk_factory/interfaces/networked_stack_mixin.py,sha256=69pJp4IE1n_tdHh2UZQ08O6ZW-v5P4uJJ_fleNaj6Nw,2897
69
69
  cdk_factory/interfaces/standardized_ssm_mixin.py,sha256=-BT-K7mro2f3taS7biAm_oaxC7z2lurUfNUpryvahXk,22680
70
- cdk_factory/interfaces/vpc_provider_mixin.py,sha256=tfe3XqWd4lf5mMHGKexDcWmS0T2CKHSP0TDDyp6MPoY,8363
70
+ cdk_factory/interfaces/vpc_provider_mixin.py,sha256=Kj0mmZd54NINprixJLs8zL-WWiSd0AQBtGdwNg8cz14,8207
71
71
  cdk_factory/lambdas/health_handler.py,sha256=dd40ykKMxWCFEIyp2ZdQvAGNjw_ylI9CSm1N24Hp2ME,196
72
72
  cdk_factory/lambdas/edge/ip_gate/handler.py,sha256=gUevgX462mqGYddtQIyJ1-Jk3oXhFmbmd46jlqjai9E,10657
73
73
  cdk_factory/pipeline/path_utils.py,sha256=fvWdrcb4onmpIu1APkHLhXg8zWfK74HcW3Ra2ynxfXM,2586
@@ -117,7 +117,7 @@ cdk_factory/stack_library/security_group/security_group_full_stack.py,sha256=yvZ
117
117
  cdk_factory/stack_library/security_group/security_group_stack.py,sha256=Zv9FCEHvSBT1cM9bXOtyIUFwhRHKCSTgvaqOyhGj0wg,14456
118
118
  cdk_factory/stack_library/simple_queue_service/sqs_stack.py,sha256=jJksWrvrvgZUMM01RZ317DOIxqIJbkYYSYu38w0jHpc,6039
119
119
  cdk_factory/stack_library/vpc/__init__.py,sha256=7pIqP97Gf2AJbv9Ebp1WbQGHYhgEbWJ52L1MzeXBybA,42
120
- cdk_factory/stack_library/vpc/vpc_stack_standardized.py,sha256=DiyrbRL_cBfkl4WMQsxuIpLYshHh7NSKWyoqiD300y8,16473
120
+ cdk_factory/stack_library/vpc/vpc_stack_standardized.py,sha256=pMFzNJUEwhI2i-ikM_SNnagT5SQGdKipoaJPqbYXpBw,17535
121
121
  cdk_factory/stack_library/websites/static_website_stack.py,sha256=A292BlKDof0JnVewkK_3JiRB04rX7J9Na0a-iz3JWzw,11243
122
122
  cdk_factory/stages/websites/static_website_stage.py,sha256=X4fpKXkhb0zIbSHx3QyddBhVSLBryb1vf1Cg2fMTqog,755
123
123
  cdk_factory/templates/README.md,sha256=ATBEjG6beYvbEAdLtZ_8xnxgFD5X0cgZoI_6pToqH90,2679
@@ -136,8 +136,8 @@ cdk_factory/utilities/os_execute.py,sha256=5Op0LY_8Y-pUm04y1k8MTpNrmQvcLmQHPQITE
136
136
  cdk_factory/utils/api_gateway_utilities.py,sha256=If7Xu5s_UxmuV-kL3JkXxPLBdSVUKoLtohm0IUFoiV8,4378
137
137
  cdk_factory/validation/config_validator.py,sha256=Pb0TkLiPFzUplBOgMorhRCVm08vEzZhRU5xXCDTa5CA,17602
138
138
  cdk_factory/workload/workload_factory.py,sha256=yDI3cRhVI5ELNDcJPLpk9UY54Uind1xQoV3spzT4z7E,6068
139
- cdk_factory-0.17.3.dist-info/METADATA,sha256=OvYCQwGtZ3Jev3-MEOQJjTRtO-n-R_VbV-Q_oE1aVcc,2451
140
- cdk_factory-0.17.3.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
141
- cdk_factory-0.17.3.dist-info/entry_points.txt,sha256=S1DPe0ORcdiwEALMN_WIo3UQrW_g4YdQCLEsc_b0Swg,53
142
- cdk_factory-0.17.3.dist-info/licenses/LICENSE,sha256=NOtdOeLwg2il_XBJdXUPFPX8JlV4dqTdDGAd2-khxT8,1066
143
- cdk_factory-0.17.3.dist-info/RECORD,,
139
+ cdk_factory-0.17.4.dist-info/METADATA,sha256=cBM2_WWn_BuKqhtAmw9QPghfq9kGLKWdAF3DDHZbJio,2451
140
+ cdk_factory-0.17.4.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
141
+ cdk_factory-0.17.4.dist-info/entry_points.txt,sha256=S1DPe0ORcdiwEALMN_WIo3UQrW_g4YdQCLEsc_b0Swg,53
142
+ cdk_factory-0.17.4.dist-info/licenses/LICENSE,sha256=NOtdOeLwg2il_XBJdXUPFPX8JlV4dqTdDGAd2-khxT8,1066
143
+ cdk_factory-0.17.4.dist-info/RECORD,,