1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2025-06-08 19:00:55 +00:00

enabled autoconfig/autodiscover for all email domains

This commit is contained in:
Jeff Volkenant 2018-12-19 11:45:16 -08:00
parent d6f3d0c86b
commit fddbbac6e7
2 changed files with 6 additions and 7 deletions

View File

@ -292,11 +292,10 @@ def build_zone(domain, all_domains, additional_records, www_redirect_domains, en
# This allows the following clients to automatically configure email addresses in the respective applications.
# autodiscover.* - Z-Push ActiveSync Autodiscover
# autoconfig.* - Thunderbird Autoconfig
if domain != env["PRIMARY_HOSTNAME"]:
if not has_rec("autodiscover", "A"):
records.append(("autodiscover", "A", env["PUBLIC_IP"], "Provides email configuration autodiscovery support for Z-Push ActiveSync Autodiscover."))
if not has_rec("autoconfig", "A"):
records.append(("autoconfig", "A", env["PUBLIC_IP"], "Provides email configuration autodiscovery support for Thunderbird Autoconfig."))
if not has_rec("autodiscover", "A"):
records.append(("autodiscover", "A", env["PUBLIC_IP"], "Provides email configuration autodiscovery support for Z-Push ActiveSync Autodiscover."))
if not has_rec("autoconfig", "A"):
records.append(("autoconfig", "A", env["PUBLIC_IP"], "Provides email configuration autodiscovery support for Thunderbird Autoconfig."))
# Sort the records. The None records *must* go first in the nsd zone file. Otherwise it doesn't matter.
records.sort(key = lambda rec : list(reversed(rec[0].split(".")) if rec[0] is not None else ""))

View File

@ -32,8 +32,8 @@ def get_web_domains(env, include_www_redirects=True, exclude_dns_elsewhere=True)
# Add Autoconfiguration domains, allowing us to serve correct SSL certs.
# 'autoconfig.' for Mozilla Thunderbird auto setup.
# 'autodiscover.' for Activesync autodiscovery.
domains |= set('autoconfig.' + zone for zone, zonefile in get_dns_zones(env))
domains |= set('autodiscover.' + zone for zone, zonefile in get_dns_zones(env))
domains |= set('autoconfig.' + maildomain for maildomain in get_mail_domains(env))
domains |= set('autodiscover.' + maildomain for maildomain in get_mail_domains(env))
# Ensure the PRIMARY_HOSTNAME is in the list so we can serve webmail
# as well as Z-Push for Exchange ActiveSync. This can't be removed