Ticket #1750: nginx-running.conf

File nginx-running.conf, 6.8 KB (added by imjosi@…, 8 years ago)

Nginx running config

Line 
1# configuration file /etc/nginx/nginx.conf:
2
3user nginx;
4worker_processes 2;
5
6error_log /var/log/nginx/error.log debug; # warn;
7pid /var/run/nginx.pid;
8
9
10events {
11 worker_connections 1024;
12}
13
14
15http {
16 include /etc/nginx/mime.types;
17 default_type application/octet-stream;
18
19 log_format main '$remote_addr - $remote_user [$time_local] "$request" '
20 '$status $body_bytes_sent "$http_referer" '
21 '"$http_user_agent" "$http_x_forwarded_for" $request_time';
22
23 access_log /var/log/nginx/access.log main;
24
25 sendfile on;
26 #tcp_nopush on;
27
28 keepalive_timeout 65;
29
30 #gzip on;
31
32 include /etc/nginx/conf.d/*.conf;
33}
34
35# configuration file /etc/nginx/mime.types:
36
37types {
38 text/html html htm shtml;
39 text/css css;
40 text/xml xml;
41 image/gif gif;
42 image/jpeg jpeg jpg;
43 application/javascript js;
44 application/atom+xml atom;
45 application/rss+xml rss;
46
47 text/mathml mml;
48 text/plain txt;
49 text/vnd.sun.j2me.app-descriptor jad;
50 text/vnd.wap.wml wml;
51 text/x-component htc;
52
53 image/png png;
54 image/svg+xml svg svgz;
55 image/tiff tif tiff;
56 image/vnd.wap.wbmp wbmp;
57 image/webp webp;
58 image/x-icon ico;
59 image/x-jng jng;
60 image/x-ms-bmp bmp;
61
62 application/font-woff woff;
63 application/java-archive jar war ear;
64 application/json json;
65 application/mac-binhex40 hqx;
66 application/msword doc;
67 application/pdf pdf;
68 application/postscript ps eps ai;
69 application/rtf rtf;
70 application/vnd.apple.mpegurl m3u8;
71 application/vnd.google-earth.kml+xml kml;
72 application/vnd.google-earth.kmz kmz;
73 application/vnd.ms-excel xls;
74 application/vnd.ms-fontobject eot;
75 application/vnd.ms-powerpoint ppt;
76 application/vnd.oasis.opendocument.graphics odg;
77 application/vnd.oasis.opendocument.presentation odp;
78 application/vnd.oasis.opendocument.spreadsheet ods;
79 application/vnd.oasis.opendocument.text odt;
80 application/vnd.openxmlformats-officedocument.presentationml.presentation
81 pptx;
82 application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
83 xlsx;
84 application/vnd.openxmlformats-officedocument.wordprocessingml.document
85 docx;
86 application/vnd.wap.wmlc wmlc;
87 application/x-7z-compressed 7z;
88 application/x-cocoa cco;
89 application/x-java-archive-diff jardiff;
90 application/x-java-jnlp-file jnlp;
91 application/x-makeself run;
92 application/x-perl pl pm;
93 application/x-pilot prc pdb;
94 application/x-rar-compressed rar;
95 application/x-redhat-package-manager rpm;
96 application/x-sea sea;
97 application/x-shockwave-flash swf;
98 application/x-stuffit sit;
99 application/x-tcl tcl tk;
100 application/x-x509-ca-cert der pem crt;
101 application/x-xpinstall xpi;
102 application/xhtml+xml xhtml;
103 application/xspf+xml xspf;
104 application/zip zip;
105
106 application/octet-stream bin exe dll;
107 application/octet-stream deb;
108 application/octet-stream dmg;
109 application/octet-stream iso img;
110 application/octet-stream msi msp msm;
111
112 audio/midi mid midi kar;
113 audio/mpeg mp3;
114 audio/ogg ogg;
115 audio/x-m4a m4a;
116 audio/x-realaudio ra;
117
118 video/3gpp 3gpp 3gp;
119 video/mp2t ts;
120 video/mp4 mp4;
121 video/mpeg mpeg mpg;
122 video/quicktime mov;
123 video/webm webm;
124 video/x-flv flv;
125 video/x-m4v m4v;
126 video/x-mng mng;
127 video/x-ms-asf asx asf;
128 video/x-ms-wmv wmv;
129 video/x-msvideo avi;
130}
131
132# configuration file /etc/nginx/conf.d/03-proxy-common.conf:
133 proxy_redirect off;
134 proxy_http_version 1.1;
135
136 proxy_set_header Host $host;
137 proxy_set_header X-Real-IP $remote_addr;
138 proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
139
140 proxy_connect_timeout 5;
141 proxy_send_timeout 10;
142 proxy_read_timeout 60;
143 proxy_buffer_size 256k;
144 proxy_buffers 16 256k;
145
146 client_max_body_size 10m;
147 client_body_buffer_size 256k;
148
149 keepalive_requests 100;
150
151# configuration file /etc/nginx/conf.d/56-TML.conf:
152server {
153 listen 8080 default_server;
154 server_name _;
155
156 proxy_no_cache now;
157 proxy_cache_bypass now;
158
159 location / {
160 root /mnt/net/ktn/ ;
161 }
162
163 # redirect server error pages to the static page /50x.html
164 #
165 error_page 500 502 503 504 /50x.html;
166 location = /50x.html {
167 root /usr/share/nginx/html;
168 }
169}
170