[Pkg-mono-devel] Re: Timeframe for libapache2-mod-mono
Sam Liddicott
sam@liddicott.com
Wed, 22 Sep 2004 00:02:43 +0100
Pablo Fischer wrote:
> Hi,
>
> El mar, 21-09-2004 a las 16:25, Sam Liddicott escribió:
>
>>Peter Magnusson wrote:
>>
>>>A description on how I did the setup can be found at
>>>http://crippledcanary.nu/monoresources/howtos/HOWTO.libapache2-mod-mono
>
> Ok, I added a new section to the website (pkg-mono.alioth.debian.org)
> called: "ASP.NET Support in Debian" with a link to the how-to :-)
>
>
>
>><IfModule mod_mono.c>
>> MonoUnixSocket /tmp/.mod_mono_server
>> MonoServerPath /usr/share/dotnet/bin/mod-mono-server.exe
>> AddType application/x-asp-net .aspx .ashx .asmx .ascx .asax .config .ascx
>> MonoApplicationsConfigDir /etc/mono-server
>> MonoPath /usr/share/dotnet/lib:/usr/lib:/usr/share/dotnet/lib:
>>
>>But the per-vhost stuff seems partial and over complicated.
>>I got it to work with just this:
>
>
> I know it's complicated :-(.
>
>>In my vhost section I just have:
>><IfModule mod_mono.c>
>> AddHandler mono .aspx
>></IfModule>
>
>
> Well, the reason of what I didn't added only that is:
>
> 1. Use a different UnixSocket (as Debian says, look .gdm_socket for
> example)
> 2. We keep our .exe's files in anoter directory, to prevent errors I
> added the full path.
> 3. MonoApplicationConfigDir and MonoPath are very obvious of why I
> declared them :-).
>>It then seems to me that any .aspx files in my document root are handled
>>by the mono-server that shares the same vhost name and document root. In
>>fact because everything is so the same I wonder that it needs to be
>>specified in debian.webapp at all and why mod_mono can't just tell it to
>>mono-server when it makes the request?
The mono-server-hosts.conf file generated by mono-server-update.conf
ignores the vhost so the alias statements it generates apply to ALL
vhosts which is very scary and naturally breaks things.
I wish there was something we could specify in
/etc/mono-server/conf.d/BLAH/10_blah which would stop it creating
entries in mono-server-hosts.conf
Just edit your mono-server-hosts.conf and take out the entries it
generates. You just don't need them at all if you have
AddHandler mono .aspx
You just need your debian.webapp to have the same vhost and docroot as
your apache vhost and make the vpath = /
>
>
> Like you, I've been asking that to my self :(. I'm waiting the day
> mod_mono will be easier as mod_php4.
one day...
> I've tried with multiple .webapps, and there's another problem (that you
> might find), mod_mono keeps the configuration in a 'cache' so..
> sometimes you have modified your debian.webapp but mod_mono will still
> reading an old one, with this I've found two solutions: If that happens,
> move the socket to another place.. restart PC (just restarting apache
> will not work).
This is the problem I have been spending hours on.
I have been doing
killall mono ; apachectl restart
but after a while mod-mono-server will never start again and a reboot
wont fix it.
I have to de-install with purge all mono packages and put them back
again before it works.
I havent found another way yet. I'm not sure how restarting apache was
starting mod-mono-server or what makes it stop working
I'm going to have to do another de-install re-install now.
Sam
>
> See ya,
> Pablo