[imp] virtualhost,apache,virtual domain

tdavis@birddog.com tdavis@birddog.com
Thu, 29 Mar 2001 01:28:47 -0600


Haha, ok here is what I found out.
Apache has a little thing called 'UseCanonicalName'
By default it is set to UseCanonicalName On
Set it to UseCanonicalName Off if you are trying to do what I am doing.  IMP 
sends a redirect and apache looks to the SERVER_NAME as the answer to give back 
to the client and that screws with the original domain name if what the client 
typed in is different than the SERVER_NAME variable or the ServerName parameter 
in httpd.conf.

Thank you guys for commenting well, otherwise I would not have found this!
It is not hard for someone who knows the code but I know grep, thank you once 
again.

Terry

Quoting tdavis@birddog.com:

> -- Quoting Chuck --
> 
> 1. Use the server list
> 2. Hide the server list
> 3. Set the preferred attribute of each mail server in the server list to the
> 
> domain name (www.ab.com, etc.) that you want users to be able to log into
> that 
> domain from.
> 
> Ok, I did this but I am still running into problems.  What is the purpose of
> 
> the preferred switch?  In the config it says that it is only useful if you
> want 
> to use the same servers.php for different machines.  
> 
> thanks for any thoughts on this. 
> 
> 
> Quoting Terry Davis <tdavis@birddog.com>:
> 
> > Here is my servers.php:
> > $servers = array();
> > 
> > $servers['domain1'] = array(
> >     'name' => 'domain1.com',
> >     'server' => 'mail.domain1.com',
> >     'protocol' => 'imap',
> >     'port' => 143,
> >     'folders' => '',
> >     'namespace' => '',
> >     'maildomain' => 'domain1.com',
> >     'preferred' => 'mail.domain1.com'
> > );
> > 
> > $servers['domain2'] = array(
> >     'name' => 'domain2.com',
> >     'server' => 'mail.domain2.com',
> >     'protocol' => 'imap',
> >     'port' => 143,
> >     'folders' => '',
> >     'namespace' => '',
> >     'maildomain' => 'domain2.com',
> >     'preferred' => 'mail.domain2.com'
> > );
> > 
> > I am using Name based virtual hosts in apache.
> > Here is that info:
> > <VirtualHost ip.address>
> >         DocumentRoot /home/web/htdocs/horde/imp
> >         ServerName mail.domain1.com
> >         ErrorLog logs/domain1-error_log
> >         CustomLog logs/domain1-access_log combined
> > </VirtualHost>
> > 
> > <VirtualHost ip.address>
> >         DocumentRoot /home/web/htdocs/horde/imp
> >         ServerName mail.domain2.com
> >         ErrorLog logs/domain2-error_log
> >         CustomLog logs/domain2-access_log combined
> > </VirtualHost>
> > 
> > If I go to http://mail.domain2.com/horde/imp like I am supposed to it
> > 'redirects' me to hostname.domain1.com.
> > 
> > Where is that coming from?
> > Thank you,
> > Terry
> > -- 
> > Terry Davis
> > Systems Administrator
> > BirdDog Solutions, Inc.
> > 2102 N 117th Ave
> > Omaha, NE 68164
> > voice: (402) 829-6059
> > fax: (402) 829-6199
> > pager: (877) 973-6995
> > tdavis@birddog.com www.birddog.com
> > 
> > -- 
> > IMP mailing list: http://horde.org/imp/
> > Frequently Asked Questions: http://horde.org/faq/
> > To unsubscribe, mail: imp-unsubscribe@lists.horde.org
> > 
> 
> 
> -------------------------------------------------
> This mail sent through IMP: http://horde.org/imp/
> 
> -- 
> IMP mailing list: http://horde.org/imp/
> Frequently Asked Questions: http://horde.org/faq/
> To unsubscribe, mail: imp-unsubscribe@lists.horde.org
> 


-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/