mirror of
https://github.com/github/octodns.git
synced 2024-05-11 05:55:00 +00:00
Always prepend a legal name to the zone name
This commit is contained in:
@@ -129,10 +129,8 @@ class GoogleCloudProvider(BaseProvider):
|
||||
# Zone name must begin with a letter, end with a letter or digit,
|
||||
# and only contain lowercase letters, digits or dashes,
|
||||
# and be 63 characters or less
|
||||
zone_name = '{}-{}'.format(
|
||||
zone_name = 'zone-{}-{}'.format(
|
||||
dns_name.replace('.', '-'), uuid4().hex)[:63]
|
||||
if not zone_name[:1].isalpha():
|
||||
zone_name = 'zone-{}'.format(zone_name[:58])
|
||||
|
||||
gcloud_zone = self.gcloud_client.zone(
|
||||
name=zone_name,
|
||||
|
||||
Reference in New Issue
Block a user