Yes. The fastcgi-mono-server4(mono 3.12.1) can take more than one webapp in single proc.
It seems that the fastcgi-mono-server only use the vhost+vport+vpath to match the webapp node defined in .webapp file.
- Setup two webapp in different port 80 vs. 81
my_nginx.conf
server {
listen 80;
server_name localhost;
location / {
root /home/test/www;
index index.html Default.aspx;
fastcgi_pass 127.0.0.1:9000;
include /etc/nginx/fastcgi_params;
}
}
server {
listen 81;
server_name localhost;
location / {
root /home/test/www2;
index index.html Default.aspx;
fastcgi_pass 127.0.0.1:9000;
include /etc/nginx/fastcgi_params;
}
}
- two.webapp
it contains 2 webapp nodes
<apps>
<web-application>
<name>www</name>
<vhost>*</vhost>
<vport>80</vport>
<vpath>/</vpath>
<path>/home/test/www/</path>
<enabled>true</enabled>
</web-application>
<web-application>
<name>www2</name>
<vhost>*</vhost>
<vport>81</vport>
<vpath>/</vpath>
<path>/home/test/www2/</path>
<enabled>true</enabled>
</web-application>
</apps>
I just tested use the vport to distinct them, and succeed. I think using vhost or vpath or any combination of vhost+vport+vpath should worked.
- start the fastcgi server
listening in 9000 port.
fastcgi-mono-server4 --appconfigfile=./two.webapp /socket=tcp:127.0.0.1:9000