[Mono-list] Re: mod_mono ignoring DirectoryIndex?

Robert Jordan robertj at gmx.net
Wed Jun 22 04:40:55 EDT 2005


Benjamin,

> I have set up an Apache virtual host to work with mod_mono. My ASP.NET
> application doesn't work yet because of some Windows-specific
> filesystem access. This is expected. However, when I access the root
> of the virtual host, I get an error message telling me of the problem
> as mono attempts to run default.aspx, despite the fact that I have no
> DirectoryIndex directive with default.aspx as an argument. There is an
> index.html in the root directory; and I expected that it should be
> served.
> 
> So in addition to the "main server" DirectoryIndex directive that
> contains index.html, I added the following inside the virtual host:
> 
> DirectoryIndex index.html
> 
> It is the only DirectoryIndex directive in the virtual host. Still,
> the problem occurs.

You're probably using "SetHandler mono". Try AddHandler:

<Directory "/physical/path/to/your/asp.net/test">
     AddHandler mono .aspx .ascx .asax .ashx .config .cs .asmx .axd
     DirectoryIndex index.html index.aspx default.aspx
</Directory>

Rob



More information about the Mono-list mailing list