[Mono-aspnet-list] How to run MVC5 app on apache2+mod_mono

Shrimpy WU shrimpywu at hotmail.com
Mon Feb 29 22:04:13 UTC 2016

Hi Everyone, 
I have a mvc5 application (NOT asp.net 5), runs fine on XSP (cd into directory and run "xsp" with admin permission) However struggling to have it run on apache2+mod_mono. When i visit "", it list all the files/folders under myapp. if i visit "", it display the raw content.  
Will be good if anyone can help and point out what did i do wrong.
Try to follow document that i think is right, but didn`t get any success "http://www.mono-project.com/docs/web/mod_mono/" "http://r2d2.cc/2014/03/25/asp-net-mvc-under-linux-with-mono/" 
Below is my config settings: 
/etc/apache2# ├── sites-available │   ├── 000-default.conf │   ├── default-ssl.conf │   └── myapp.conf └── sites-enabled     ├── 000-default.conf -> ../sites-available/000-default.conf     └── myapp.conf -> ../sites-available/myapp.conf 

Content from myapp.conf: 
  Alias /myapp "/var/www/html/myapp"   MonoServerPath myapp "/usr/bin/mod-mono-server4"   MonoDebug myapp true   MonoSetEnv myapp MONO_IOMAP=all 
  MonoAutoApplication disabled   AddHandler mono .aspx .ascx .asax .ashx .config .cs .asmx .axd   MonoApplications myapp "/myapp:/var/www/html/myapp"   <Location "/myapp">    Allow from all     Order allow,deny     MonoSetServerAlias myapp     SetHandler mono     SetOutputFilter DEFLATE     SetEnvIfNoCase Request_URI "\.(?:gif|jpe?g|png)$" no-gzip dont-vary   </Location>  <IfModule mod_deflate.c>    AddOutputFilterByType DEFLATE text/html text/plain text/xml text/javascript   </IfModule> 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-aspnet-list/attachments/20160229/78085aeb/attachment.html>

More information about the Mono-aspnet-list mailing list