~dricottone/huttese

ref: 6476da76a8eeec0a2a48c53eefcaf3eae20c144a huttese/sr/etc/nginx/http.d/test.conf -rw-r--r-- 771 bytes
6476da76Dominic Ricottone Refactoring 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
server {
	listen 8080 default_server;
	server_name _;

	root /usr/share/nginx/html;

	location ~ [^/]\.cgi(/|$) {
		fastcgi_split_path_info ^(.+?\.cgi)(/.*)$;
		if (!-f $document_root$fastcgi_script_name) {
		    return 404;
		}
		
		fastcgi_param HTTP_PROXY "";
		
		fastcgi_pass localhost:9000;
		fastcgi_index index.php;
		
		include fastcgi_params;
	
		fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
	}

	location ~ [^/]\.php(/|$) {
		fastcgi_split_path_info ^(.+?\.php)(/.*)$;
		if (!-f $document_root$fastcgi_script_name) {
		    return 404;
		}
		
		fastcgi_param HTTP_PROXY "";
		
		fastcgi_pass localhost:9000;
		fastcgi_index index.php;
		
		include fastcgi_params;
	
		fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
	}
}