Route53 - fixed endpoint creation without ip address (#5246)

This commit is contained in:
Macwan Nevil 2022-06-21 02:43:49 +05:30 committed by GitHub
parent e004c6d218
commit c2b1950698
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 0 deletions

View File

@ -445,6 +445,13 @@ class Route53ResolverBackend(BaseBackend):
f"Account '{get_account_id()}' has exceeded 'max-endpoints'"
)
for x in ip_addresses:
if not x.get("Ip"):
subnet_info = ec2_backends[region].get_all_subnets(
subnet_ids=[x["SubnetId"]]
)[0]
x["Ip"] = subnet_info.get_available_subnet_ip(self)
self._verify_subnet_ips(region, ip_addresses)
self._verify_security_group_ids(region, security_group_ids)
if creator_request_id in [

View File

@ -189,6 +189,7 @@ route53:
- TestAccRoute53HealthCheck_withSNI
- TestAccRoute53HealthCheck_disabled
- TestAccRoute53HealthCheck_disappears
- TestAccRoute53ResolverEndpoint_basicInbound
s3:
- TestAccS3BucketPolicy
- TestAccS3BucketPublicAccessBlock