1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2026-03-15 17:37:22 +01:00

add mail alias checks and other cleanup

This commit is contained in:
Joshua Tauberer
2014-06-22 16:28:55 +00:00
parent deab8974ec
commit 343886d818
2 changed files with 43 additions and 12 deletions

View File

@@ -16,9 +16,10 @@ def get_dns_domains(env):
domains.add(env['PUBLIC_HOSTNAME'])
return domains
def get_dns_zones(domains, env):
def get_dns_zones(env):
# What domains should we create DNS zones for? Never create a zone for
# a domain & a subdomain of that domain.
domains = get_dns_domains(env)
# Exclude domains that are subdomains of other domains we know. Proceed
# by looking at shorter domains first.
@@ -49,7 +50,7 @@ def get_dns_zones(domains, env):
def do_dns_update(env):
# What domains (and their zone filenames) should we build?
domains = get_dns_domains(env)
zonefiles = get_dns_zones(domains, env)
zonefiles = get_dns_zones(env)
# Write zone files.
os.makedirs('/etc/nsd/zones', exist_ok=True)