chore(vpc): add mapPublicIpOnLaunch attribute to VPC subnets (#2470)

This commit is contained in:
Sebastian Nyberg
2023-06-09 13:45:28 +03:00
committed by GitHub
parent b73da9c54c
commit 3c2c896708
2 changed files with 6 additions and 0 deletions

View File

@@ -294,6 +294,7 @@ class VPC:
public=public,
nat_gateway=nat_gateway,
tags=subnet.get("Tags"),
mapPublicIpOnLaunch=subnet["MapPublicIpOnLaunch"],
)
self.vpc_subnets[subnet["SubnetId"]] = object
# Add it to the VPC object
@@ -319,6 +320,7 @@ class VpcSubnet(BaseModel):
public: bool
nat_gateway: bool
region: str
mapPublicIpOnLaunch: bool
tags: Optional[list] = []

View File

@@ -108,6 +108,7 @@ class Test_networkfirewall_in_all_vpc:
nat_gateway=False,
region=AWS_REGION,
tags=[],
mapPublicIpOnLaunch=False,
)
],
tags=[],
@@ -171,6 +172,7 @@ class Test_networkfirewall_in_all_vpc:
nat_gateway=False,
region=AWS_REGION,
tags=[],
mapPublicIpOnLaunch=False,
)
],
tags=[],
@@ -244,6 +246,7 @@ class Test_networkfirewall_in_all_vpc:
nat_gateway=False,
region=AWS_REGION,
tags=[],
mapPublicIpOnLaunch=False,
)
],
tags=[],
@@ -265,6 +268,7 @@ class Test_networkfirewall_in_all_vpc:
nat_gateway=False,
region=AWS_REGION,
tags=[],
mapPublicIpOnLaunch=False,
)
],
tags=[],