[Mono-list] Apache virtual hosts, all or some mod_mono

Andrew Arnott AndrewArnott@byu.edu
Wed, 28 Apr 2004 14:10:34 -0600


Maybe I can make my question more clear.
=20
I have one Apache 2.0 server running.  It must handle requests for =
several domains:
=20
gerontology.byu.edu
fhss.byu.edu
familylife.byu.edu
and anyway you get the idea.
=20
Several of these domains will be sites that use mod_mono, all on the =
same Apache 2.0.49 server. I can use "virtual hosts" in Apache to get =
Apache to respond with different root directories for each URL request.  =
My problem is getting mod_mono to also recognize the virtual hosts (NOT =
virtual directories within one host) and serve up the correct root =
directories.=20
=20
Here is what we are trying in httpd.conf:
=20
LoadModule mono_module modules/libmod_mono.so
# Note that these next paths are NOT virtual directories, but should be =
roots in virtual hosts
MonoApplications =
"/:/var/www/gerontology,/:/var/www/fhss,/:/var/www/familylife"
# ...
NameVirtualHost *:80
<VirtualHost *:80>
     ServerName gerontology.byu.edu
     DocumentRoot /var/www/gerontology
</VirtualHost>
<VirtualHost *:80>
    ServerName fhss.byu.edu
    DocumentRoot /var/www/fhss
</VirtualHost>
=20
The trouble is that mod_mono appears to be trying to pull, for example, =
FHSS.byu.edu content from gerontology.byu.edu.  There is no way to =
specify virtual hosts in the MonoApplications directive, rather just =
virtual directories, which doesn't fit here.
=20
Thanks in advance for your help!
=20
Andrew Arnott

________________________________

From: mono-list-admin@lists.ximian.com on behalf of Gonzalo Paniagua =
Javier
Sent: Tue 4/27/2004 2:31 AM
To: mono-list@lists.ximian.com
Subject: Re: [Mono-list] Apache virtual hosts, all or some mod_mono



El lun, 26-04-2004 a las 22:53, Andrew Arnott escribi=F3:=20
> I am trying to set up multiple virtual hosts on Apache 2.0.49.  Each=20
> of which of course has its own physical root directory.  Trouble is=20
> the MonoApplications line only takes virtual directory paths.  Running =

> mod-mono-server.exe and looking at the argument syntax doesn't help.=20
> How can I have multiple virtual roots on various virtual hosts, and=20
> configure Mono to work on them all?=20

MonoApplications takes virtual:physical pairs separated by a comma.=20

For your purpose, you have to use the 'Alias virtual "physical"' apache=20
directive and when configuring the virtual host, set mod_mono as the=20
handler for the virtual directory for that virtual host.=20

-Gonzalo=20

_______________________________________________=20
Mono-list maillist  -  Mono-list@lists.ximian.com=20
http://lists.ximian.com/mailman/listinfo/mono-list=20