mail-in-a-box / mailinabox

Mail-in-a-Box helps individuals take back control of their email by defining a one-click, easy-to-deploy SMTP+everything else server: a mail server in a box.
https://mailinabox.email/
Creative Commons Zero v1.0 Universal
14.06k stars 1.44k forks source link

configure webmail address on mail.mydomain.com #1867

Open guizmoau opened 4 years ago

guizmoau commented 4 years ago

hi there,

I am trying to find a way to configure the address on roundcube webmail to be available as a subdomain like mail.mydomain.com in the case of a multiple domain configuration.

How can I do so ?

MarkIvanowich commented 3 years ago

Since mailinabox will self-update and overwrite your configs, so this is not recommended. The generated/active nginx file is in /etc/nginx/conf.d/local.conf, which periodically gets generated by templates mailinabox/conf/ folder. Those templates are at risk of being overwritten by an update.

Your safest bet would be to:

header("Location: https://primarydomain.com/mail");
die();

When someone visits mail.mydomain.com, they will be redirected to your primary domain webmail.