catch / handle DnsUpdateError (e.g. SERVFAIL)

This commit is contained in:
Thomas Waldmann 2014-04-28 00:47:28 +02:00
parent b0c797f34d
commit b818ea9df9

View File

@ -198,6 +198,8 @@ class OverviewView(CreateView):
success, level, msg = False, messages.ERROR, 'Timeout - communicating to name server failed.' success, level, msg = False, messages.ERROR, 'Timeout - communicating to name server failed.'
except dnstools.NameServerNotAvailable: except dnstools.NameServerNotAvailable:
success, level, msg = False, messages.ERROR, 'Name server unavailable.' success, level, msg = False, messages.ERROR, 'Name server unavailable.'
except dnstools.DnsUpdateError as e:
success, level, msg = False, messages.ERROR, 'DNS update error [%s].' % str(e)
except Domain.DoesNotExist: except Domain.DoesNotExist:
# should not happen: POST data had invalid (base)domain # should not happen: POST data had invalid (base)domain
success, level, msg = False, messages.ERROR, 'Base domain does not exist.' success, level, msg = False, messages.ERROR, 'Base domain does not exist.'