Skip to content

Commit

Permalink
Merge pull request #3 from eill/master
Browse files Browse the repository at this point in the history
TTL setting support for A and AAAA record types
  • Loading branch information
shabarin authored Nov 12, 2019
2 parents 708f814 + e6a4962 commit 382d319
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions yandexdns.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,8 @@ def dnsrecord_add(self):
'content' : self.content,
'subdomain' : self.subdomain,
}
if self.type == 'A' or self.type == 'AAAA':
post_data['ttl'] = self.ttl
if self.type == 'SOA':
post_data['admin_mail'] = self.admin_mail
post_data['ttl'] = self.ttl
Expand Down Expand Up @@ -142,6 +144,8 @@ def dnsrecord_mod(self):
'content' : self.content,
'priority' : self.priority
}
if self.type == 'A' or self.type == 'AAAA':
post_data['ttl'] = self.ttl
if self.type == 'SOA':
post_data['ttl'] = self.ttl
post_data['admin_mail'] = self.admin_mail
Expand Down

0 comments on commit 382d319

Please sign in to comment.