Configuring autodiscover

While using ActiveSync allows for entering server name explicitly, it's possible to configure autodiscover feature so that email client can get matching ActiveSync server details from a email address.

Please bear in mind that this configuration is performed for primary domain. For example, if you have WebMail Pro installed at webmail.domain.com and ActiveServer is available at sync.domain.com, autodiscover needs to be configured for domain.com host, and it's assumed that you're dealing with @domain.com email addresses.

If reconfiguring primary domain is not an option, you can set up autodiscover.domain.com - most clients would check both and use whichever one is available.

Actually, to discover settings for email account in domain.com domain, email clients check against URL of the following kind:

domain.com/Autodiscover/Autodiscover.xml

or:

autodiscover.domain.com/Autodiscover/Autodiscover.xml

So if you wish to have autodiscover enabled, reconfigure your web server by adding an alias pointing from URL of that kind to autodiscover/autodiscover.php.

Also, you need to edit autodiscover/config.php file, uncomment the following line and specify ActiveServer hostname there:

define('ZPUSH_HOST', 'sync.domain.com');

Apache configuration

# Z-Push AutoDiscover - ActiveSync over-the-air - default Apache configuration
<IfModule mod_alias.c>
    AliasMatch (?i)/Autodiscover/Autodiscover.xml "/usr/share/z-push/autodiscover/autodiscover.php"
</IfModule>

Nginx configuration

location ~ /(?:a|A)utodiscover/(?:a|A)utodiscover.xml {
    root /opt/afterlogic/html/sync.afterlogic.com/;
    try_files /autodiscover.php =404;
    fastcgi_pass    127.0.0.1:7777;
    fastcgi_index   index.php;
    include         fastcgi.conf;
    fastcgi_param   SERVER_ADDR "";
    fastcgi_param   REMOTE_ADDR $http_x_real_ip;
}