You are not logged in.
Login or Register

Tip: Set up Virtual Hosts in Exim with Separate Aliases

Posted By: apeiro

This is a basic outline of how to setup virtual hosts in Exim with separate aliases for each domain.

  • Make sure each domain is in local_domains
  • Add this to the routers section, after dnslookup
# This route is for domain-specific aliases.  It supports a wildcard
# alias to be used as a catch-all
virtual:
  driver = redirect 
  allow_fail
  allow_defer
  domains = domain1.com:domain2.com
  data = ${lookup{$local_part}lsearch*{/etc/mail/virtual/${domain}}}
  file_transport = address_file
  pipe_transport = address_pipe
  • In /etc/mail/virtual, create a separate file for each domain, named after the domain itself. This will be the aliases file. You can use a wildcard alias if you want.
info: info@otherdomain.com
*: webmaster@domain.com