Skip to content

Commit

Permalink
Update dnspython
Browse files Browse the repository at this point in the history
Fixes #22
  • Loading branch information
Trellmor committed Aug 4, 2020
1 parent 9a5083a commit a1ad502
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
10 changes: 5 additions & 5 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
certifi==2019.9.11
certifi==2020.6.20
chardet==3.0.4
dnspython==1.16.0
idna==2.8
dnspython==2.0.0
idna==2.10
pathlib==1.0.1
requests==2.22.0
urllib3==1.25.7
requests==2.24.0
urllib3==1.25.10
5 changes: 3 additions & 2 deletions update-zonefile.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,8 +220,9 @@ def load_zone(zonefile, origin, raw):
return dns.zone.from_text(zone_text, origin)

def update_serial(zone):
soa = zone.get_rdataset('@', dns.rdatatype.SOA)[0]
soa.serial += 1
soaset = zone.get_rdataset('@', dns.rdatatype.SOA)
soa = soaset[0]
soaset.add(soa.replace(serial=soa.serial + 1))

def check_zone(origin, zonefile):
cmd = ['named-checkzone', '-q', origin, str(zonefile)]
Expand Down

0 comments on commit a1ad502

Please sign in to comment.