Merge pull request #2950 from hosseinsh/route53-private-zone-fix

fixing the private DNS zone issue.
This commit is contained in:
Hossein Shafagh 2020-04-24 16:08:38 -07:00 committed by GitHub
commit f71a9e0ad2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 3 deletions

View File

@ -35,6 +35,7 @@ def get_zones(client=None):
zones = [] zones = []
for page in paginator.paginate(): for page in paginator.paginate():
for zone in page["HostedZones"]: for zone in page["HostedZones"]:
if not zone["Config"]["PrivateZone"]:
zones.append( zones.append(
zone["Name"][:-1] zone["Name"][:-1]
) # We need [:-1] to strip out the trailing dot. ) # We need [:-1] to strip out the trailing dot.