Update configuration.py

This commit is contained in:
Matthew Ames
2015-11-17 09:27:15 +00:00
parent d6b4e73d9d
commit b20acaa3e1
+1 -1
View File
@@ -157,6 +157,6 @@ def _check_config_domain_sanity(domains):
# http://www.mkyong.com/regular-expressions/domain-name-regular-expression-example/
# Characters used, domain parts < 63 chars, tld > 1 < 7 chars
# first and last char is not "-"
fqdn = re.compile("^((?!-)[A-Za-z0-9-]{1,63}(?<!-)\\.)+[A-Za-z]{2,6}$")
fqdn = re.compile("^((?!-)[A-Za-z0-9-]{1,63}(?<!-)\\.)+[A-Za-z]{2,12}$")
if any(True for d in domains if not fqdn.match(d)):
raise errors.ConfigurationError("Requested domain is not a FQDN")