allow the dns api to set srv records

see https://discourse.mailinabox.email/t/create-srv-record-at-the-dns-server/225
This commit is contained in:
Joshua Tauberer 2015-01-02 23:39:09 +00:00
parent c4e4805160
commit fddab5d432
2 changed files with 2 additions and 1 deletions

View File

@ -12,6 +12,7 @@ Control panel:
* Status checks would fail to load if openssh-sever was not pre-installed, but openssh-server is not required.
* The local DNS cache is cleared before running the status checks using 'rncd' now rather than restarting 'bind9', which should be faster and wont interrupt other services.
* The DNS API now allows the setting of SRV records.
Misc:

View File

@ -669,7 +669,7 @@ def set_custom_dns_record(qname, rtype, value, env):
v = ipaddress.ip_address(value)
if rtype == "A" and not isinstance(v, ipaddress.IPv4Address): raise ValueError("That's an IPv6 address.")
if rtype == "AAAA" and not isinstance(v, ipaddress.IPv6Address): raise ValueError("That's an IPv4 address.")
elif rtype in ("CNAME", "TXT"):
elif rtype in ("CNAME", "TXT", "SRV"):
# anything goes
pass
else: