[Mono-aspnet-list] Fwd: Web-Service On Nginx

amru rosyada amru.rosyada at gmail.com
Thu Feb 2 04:45:52 UTC 2017


Hi,

May be you should remove this line:

try_files $uri $uri/ =404;

and don’t forget to set your root folder to your application root folder in this line

root /var/www; ==> set to your root app folder 

and you also need to start fast cgi service to passs your asp page

fastcgi-mono-server4 /applications=/:/path to your application folder/ /socket=tcp:127.0.0.1:9000


Hope it help,

Regards,

> On Feb 2, 2017, at 9:38 AM, nikhil sehgal <nikhil.jiet at gmail.com> wrote:
> 
> ---------- Forwarded message ----------
> From: "nikhil sehgal" <nikhil.jiet at gmail.com <mailto:nikhil.jiet at gmail.com>>
> Date: Feb 1, 2017 11:08 PM
> Subject: Web-Service On Nginx
> To: <mono-devel-list at lists.dot.net <mailto:mono-devel-list at lists.dot.net>>, <mono-list at lists.dot.net <mailto:mono-list at lists.dot.net>>
> Cc: 
> 
> HI ALL,
> 
> 
> I am trying to host simple web-service on Nginx using Fast CGI on https .
> 
> I am so sorry asking for some silly error .
> 
> I am Getting following error .it is not able to find my class (in dll)
> <image.png>
> 
> Following are my configuration 
> 
> gedit /etc/nginx/sites-available/default(PFA)
> 
> 
> isten 443;
> 	server_name localhost;
> 
> 	root /var/www;
> 	#index index.html index.htm;
> 
> 	ssl on;
> 	ssl_certificate cert.crt;
> 	ssl_certificate_key cert.key;
> 
> 	ssl_session_timeout 5m;
> 
> 	ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2;
> 	ssl_ciphers "HIGH:!aNULL:!MD5 or HIGH:!aNULL:!MD5:!3DES";
> 	ssl_prefer_server_ciphers on;
> 
> 	location / {
> 		try_files $uri $uri/ =404;
>  		index index.html index.htm index.aspx;
>                 fastcgi_index Default.aspx;
>                 fastcgi_pass 127.0.0.1:9000 <http://127.0.0.1:9000/>;
>                 include /etc/nginx/fastcgi_params;
> 	}
> }
> 
> etc/nginx/fastcgi_params(PFA file)
> 
> 
> fastcgi_param	QUERY_STRING		$query_string;
> fastcgi_param	REQUEST_METHOD		$request_method;
> fastcgi_param	CONTENT_TYPE		$content_type;
> fastcgi_param	CONTENT_LENGTH		$content_length;
> 
> #fastcgi_param	SCRIPT_FILENAME		$request_filename;
> fastcgi_param	SCRIPT_NAME		$fastcgi_script_name;
> fastcgi_param	REQUEST_URI		$request_uri;
> fastcgi_param	DOCUMENT_URI		$document_uri;
> fastcgi_param	DOCUMENT_ROOT		$document_root;
> fastcgi_param	SERVER_PROTOCOL		$server_protocol;
> 
> fastcgi_param	GATEWAY_INTERFACE	CGI/1.1;
> fastcgi_param	SERVER_SOFTWARE		nginx/$nginx_version;
> 
> fastcgi_param	REMOTE_ADDR		$remote_addr;
> fastcgi_param	REMOTE_PORT		$remote_port;
> fastcgi_param	SERVER_ADDR		$server_addr;
> fastcgi_param	SERVER_PORT		$server_port;
> fastcgi_param	SERVER_NAME		$server_name;
> 
> fastcgi_param	HTTPS			$https if_not_empty;
> fastcgi_param  PATH_INFO          "";
> fastcgi_param  SCRIPT_FILENAME    $document_root$fastcgi_script_name;
> 
> # PHP only, required if PHP was built with --enable-force-cgi-redirect
> fastcgi_param	REDIRE   T_STATUS		200;
> 
> 
> 
> webapp file fastcgi configurationnlocaled at 
> /home/nikhil/www/mono-fastcgi/aspnet.webapp(PFA)
> 
> 
> <apps>
>   <web-application>
>     <name>aspnet</name>
>     <vhost>*</vhost>
>     <vport>443</vport>
>     <vpath>/</vpath>
>     <path>/var/www</path>
>   </web-application>
> </apps>
> 
> location of web service var/www/webservice
> 
> <image.png>
> 
> 
> <image.png>
> 
> <default><fastcgi_params><aspnet.webapp>_______________________________________________
> Mono-aspnet-list mailing list
> Mono-aspnet-list at lists.dot.net
> http://lists.dot.net/mailman/listinfo/mono-aspnet-list

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dot.net/pipermail/mono-aspnet-list/attachments/20170202/8242ae5e/attachment.html>


More information about the Mono-aspnet-list mailing list