[imp] Re: Single Web Server Multiple Mail Domain

Scott Geiger scott at bcmediagroup.com
Mon Mar 28 08:25:20 PST 2005


I use qmail and have some ENV vars set in Apache; e.g. QMAILDOMAIN, 
QMAILHOST, etc.  I use those variables in the servers.php and any other 
place that requires a specific host name.  In Apache's httpd.conf I 
have a virtual domain setup like this:

<VirtualHost 192.168.0.41>
    User webmail
    Group webmail
    DocumentRoot /home/httpd/html/horde3
    ServerName webmail.domain1.com
    ErrorLog /var/log/httpd/webmail_error_log
    CustomLog /var/log/httpd/webmail_access_log combined
# Qmail ENV directives
   SetEnv QMAILDEFAULTDOMAIN domain1.com
   SetEnv QMAILDEFAULTHOST domain1.com
   SetEnv QMAILIDHOST domain1.com
   SetEnv QMAILUSER webmaster
   SetEnv QMAILHOST domain1.com
</VirtualHost>

Then I can reference $_SERVER['QMAILHOST'] in the servers.php file.  
You could make the ENV var anything you want of course - watch out if 
you are running suexec tho - the var MUST be defined in suexec.c or it 
will complain.  You could even do this on a Mass Virtual Domain setup 
if you wanted.

Scott Geiger


Quoting Nate <nmollring at cennecs.org>:

> Quoting Lewis Lee <lewislee at nbase.com.hk>:
>
>> Hi hi,
>>
>> 	I like Horde and IMP and would like to use them for my server. I'm
>> using sendmail with Horde 3.1-cvs with IMP4.1-cvs. But my problem is that
>> in
>> my case, I've only one server that act as the IMP server and the web
>> server.
>> I've several domain email to be received from it. But then, every user
>> login
>> may have only one domain as their email address that is:
>>
>> Username is only 'user1', 'user2', 'user3' to login to system, and their
>> email address is:
>>
>> user1 at domain1.com
>> user2 at domain2.com
>> user3 at domain3.com
>>
>> But after login to IMP
>>
>> user1 at domain1.com
>> user2 at domain1.com
>> user3 at domain1.com
>
> I have a separate entry for each domain in servers.php.
> Each domain uses it's own login domain.   http://domain1.com/horde
> http://domain2.com/horde  http://domain3.com/horde
> The login screen is actually the same, just the address is unique.
> When they login in using the correct domain, that domain is used throughout
> horde (imp will send e-mail from the correct domain).  It doesn't 
> seem logical
> to go to http://domain1.com/horde when that user is actually from 
> domain3.com.
> Of course that's me and my set-up :)
> Nate
>
>
> ------------------------------------------------------------------------------
> This message is intended only for the recipient. If you
> are not the intended recipient please delete this message.
> --
> IMP mailing list - Join the hunt: http://horde.org/bounties/#imp
> Frequently Asked Questions: http://horde.org/faq/
> To unsubscribe, mail: imp-unsubscribe at lists.horde.org
>





More information about the imp mailing list