How to setup access to webmail over mail.domain.com as well as webmail.domain.com

Created:

2016-11-16 13:15:02 UTC

Modified:

2017-08-16 17:05:59 UTC

0

Was this article helpful?


Have more questions?

Submit a request

How to setup access to webmail over mail.domain.com as well as webmail.domain.com

Applicable to:

  • Plesk 11.x for Linux
  • Plesk 12.0 for Linux

Question

How to setup access to webmail over mail.domain.com as well as webmail.domain.com?

Answer

  1. Create custom folder inside /usr/local/psa/admin/conf/templates directory:

    # mkdir /usr/local/psa/admin/conf/templates/custom
  2. Copy domainWebmail.php template to custom directory:

    # cp /usr/local/psa/admin/conf/templates/default/domainWebmail.php /usr/local/psa/admin/conf/templates/custom/domainWebmail.php
  3. Modify domainWebmail.php in /custom directory as follows:

    # cat /usr/local/psa/admin/conf/templates/custom/domainWebmail.php
    <?php echo AUTOGENERATED_CONFIGS; ?>

    <?php /** @var Template_VariableAccessor $VAR */ ?>
    <?php
    if (!$VAR->domain->webmailActive) {
    echo "# Domain is disabled or suspended\

    "; return; } ?> ServerAlias "webmail.<?php echo $VAR->domain->asciiName ?>" ServerAlias "mail.<?php echo $VAR->domain->asciiName ?>" <?php foreach ($VAR->domain->mailAliases AS $alias): ?> ServerAlias "webmail.<?php echo $alias->asciiName ?>" ServerAlias "mail.<?php echo $alias->asciiName ?>" <?php endforeach; ?>

  4. After that rebuild web configuration files:

    # /usr/local/psa/admin/bin/httpdmng --reconfigure-all
Have more questions? Submit a request
Please sign in to leave a comment.