| @@ -1,91 +1,93 @@ | | | @@ -1,91 +1,93 @@ |
1 | $NetBSD: patch-aa,v 1.2 2010/01/23 16:32:11 joerg Exp $ | | 1 | $NetBSD: patch-aa,v 1.3 2011/12/04 14:41:01 shattered Exp $ |
2 | | | 2 | |
3 | This patch provides config file adapted to pkgsrc settings. | | 3 | This patch provides config file adapted to pkgsrc settings. |
4 | --- conf/nginx.conf.orig 2008-02-28 22:44:16.000000000 +0200 | | 4 | |
| | | 5 | --- conf/nginx.conf.orig 2011-06-27 15:47:51.000000000 +0000 |
5 | +++ conf/nginx.conf | | 6 | +++ conf/nginx.conf |
6 | @@ -2,12 +2,13 @@ | | 7 | @@ -1,28 +1,29 @@ |
| | | 8 | |
7 | -#user nobody; | | 9 | -#user nobody; |
8 | +user %%NGINX_USER%% %%NGINX_GROUP%%; | | 10 | +user %%NGINX_USER%% %%NGINX_GROUP%%; |
9 | worker_processes 1; | | 11 | worker_processes 1; |
10 | | | 12 | |
11 | -#error_log logs/error.log; | | 13 | -#error_log logs/error.log; |
12 | -#error_log logs/error.log notice; | | 14 | -#error_log logs/error.log notice; |
13 | -#error_log logs/error.log info; | | 15 | -#error_log logs/error.log info; |
14 | - | | 16 | - |
15 | -#pid logs/nginx.pid; | | 17 | -#pid logs/nginx.pid; |
16 | +#error_log %%NGINX_LOGDIR%%/error.log; | | 18 | +#error_log %%NGINX_LOGDIR%%/error.log; |
17 | +#error_log %%NGINX_LOGDIR%%/error.log notice; | | 19 | +#error_log %%NGINX_LOGDIR%%/error.log notice; |
18 | +#error_log %%NGINX_LOGDIR%%/error.log info; | | 20 | +#error_log %%NGINX_LOGDIR%%/error.log info; |
19 | | | 21 | |
20 | +#pid %%NGINX_PIDDIR%%/nginx.pid; | | 22 | +#pid %%NGINX_PIDDIR%%/nginx.pid; |
21 | | | 23 | |
22 | events { | | 24 | events { |
23 | + # After increasing this value You probably should increase limit | | 25 | + # After increasing this value You probably should increase limit |
24 | + # of file descriptors (for example in start_precmd in startup script) | | 26 | + # of file descriptors (for example in start_precmd in startup script) |
25 | worker_connections 1024; | | 27 | worker_connections 1024; |
26 | @@ -15,14 +14,14 @@ | | 28 | } |
27 | | | 29 | |
28 | | | 30 | |
29 | http { | | 31 | http { |
30 | - include mime.types; | | 32 | - include mime.types; |
31 | + include %%PKG_SYSCONFDIR%%/mime.types; | | 33 | + include %%PKG_SYSCONFDIR%%/mime.types; |
32 | default_type application/octet-stream; | | 34 | default_type application/octet-stream; |
33 | | | 35 | |
34 | #log_format main '$remote_addr - $remote_user [$time_local] "$request" ' | | 36 | #log_format main '$remote_addr - $remote_user [$time_local] "$request" ' |
35 | # '$status $body_bytes_sent "$http_referer" ' | | 37 | # '$status $body_bytes_sent "$http_referer" ' |
36 | # '"$http_user_agent" "$http_x_forwarded_for"'; | | 38 | # '"$http_user_agent" "$http_x_forwarded_for"'; |
37 | | | 39 | |
38 | - #access_log logs/access.log main; | | 40 | - #access_log logs/access.log main; |
39 | + #access_log %%NGINX_LOGDIR%%/access.log main; | | 41 | + #access_log %%NGINX_LOGDIR%%/access.log main; |
40 | | | 42 | |
41 | sendfile on; | | 43 | sendfile on; |
42 | #tcp_nopush on; | | 44 | #tcp_nopush on; |
43 | @@ -38,10 +37,10 @@ | | 45 | @@ -38,10 +39,10 @@ http { |
44 | | | 46 | |
45 | #charset koi8-r; | | 47 | #charset koi8-r; |
46 | | | 48 | |
47 | - #access_log logs/host.access.log main; | | 49 | - #access_log logs/host.access.log main; |
48 | + #access_log %%NGINX_LOGDIR%%/host.access.log main; | | 50 | + #access_log %%NGINX_LOGDIR%%/host.access.log main; |
49 | | | 51 | |
50 | location / { | | 52 | location / { |
51 | - root html; | | 53 | - root html; |
52 | + root share/examples/nginx/html; | | 54 | + root share/examples/nginx/html; |
53 | index index.html index.htm; | | 55 | index index.html index.htm; |
54 | } | | 56 | } |
55 | | | 57 | |
56 | @@ -51,7 +50,7 @@ | | 58 | @@ -51,7 +52,7 @@ http { |
57 | # | | 59 | # |
58 | error_page 500 502 503 504 /50x.html; | | 60 | error_page 500 502 503 504 /50x.html; |
59 | location = /50x.html { | | 61 | location = /50x.html { |
60 | - root html; | | 62 | - root html; |
61 | + root share/examples/nginx/html; | | 63 | + root share/examples/nginx/html; |
62 | } | | 64 | } |
63 | | | 65 | |
64 | # proxy the PHP scripts to Apache listening on 127.0.0.1:80 | | 66 | # proxy the PHP scripts to Apache listening on 127.0.0.1:80 |
65 | @@ -67,7 +66,7 @@ | | 67 | @@ -67,7 +68,7 @@ http { |
66 | # fastcgi_pass 127.0.0.1:9000; | | 68 | # fastcgi_pass 127.0.0.1:9000; |
67 | # fastcgi_index index.php; | | 69 | # fastcgi_index index.php; |
68 | # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name; | | 70 | # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name; |
69 | - # include fastcgi_params; | | 71 | - # include fastcgi_params; |
70 | + # include %%PKG_SYSCONFDIR%%/fastcgi_params; | | 72 | + # include %%PKG_SYSCONFDIR%%/fastcgi_params; |
71 | #} | | 73 | #} |
72 | | | 74 | |
73 | # deny access to .htaccess files, if Apache's document root | | 75 | # deny access to .htaccess files, if Apache's document root |
74 | @@ -87,7 +86,7 @@ | | 76 | @@ -87,7 +88,7 @@ http { |
75 | # server_name somename alias another.alias; | | 77 | # server_name somename alias another.alias; |
76 | | | 78 | |
77 | # location / { | | 79 | # location / { |
78 | - # root html; | | 80 | - # root html; |
79 | + # root share/examples/nginx/html; | | 81 | + # root share/examples/nginx/html; |
80 | # index index.html index.htm; | | 82 | # index index.html index.htm; |
81 | # } | | 83 | # } |
82 | #} | | 84 | #} |
83 | @@ -110,7 +109,7 @@ | | 85 | @@ -110,7 +111,7 @@ http { |
84 | # ssl_prefer_server_ciphers on; | | 86 | # ssl_prefer_server_ciphers on; |
85 | | | 87 | |
86 | # location / { | | 88 | # location / { |
87 | - # root html; | | 89 | - # root html; |
88 | + # root share/examples/nginx/html; | | 90 | + # root share/examples/nginx/html; |
89 | # index index.html index.htm; | | 91 | # index index.html index.htm; |
90 | # } | | 92 | # } |
91 | #} | | 93 | #} |