Browse Source

add new value delegation_set_id to aws provider

pull/430/head
Joshua Hügli 6 years ago
parent
commit
bec8c086da
1 changed files with 7 additions and 1 deletions
  1. +7
    -1
      octodns/provider/route53.py

+ 7
- 1
octodns/provider/route53.py View File

@ -618,8 +618,9 @@ class Route53Provider(BaseProvider):
def __init__(self, id, access_key_id=None, secret_access_key=None,
max_changes=1000, client_max_attempts=None,
session_token=None, *args, **kwargs):
session_token=None, delegation_set_id=None, *args, **kwargs):
self.max_changes = max_changes
self.delegation_set_id = delegation_set_id
_msg = 'access_key_id={}, secret_access_key=***, ' \
'session_token=***'.format(access_key_id)
use_fallback_auth = access_key_id is None and \
@ -676,7 +677,12 @@ class Route53Provider(BaseProvider):
ref = uuid4().hex
self.log.debug('_get_zone_id: no matching zone, creating, '
'ref=%s', ref)
if self.delegation_set_id:
resp = self._conn.create_hosted_zone(Name=name,
CallerReference=ref,
DelegationSetId=self.delegation_set_id)
else:
resp = self._conn.create_hosted_zone(Name=name,
CallerReference=ref)
self.r53_zones[name] = id = resp['HostedZone']['Id']
return id


Loading…
Cancel
Save