|
@@ -0,0 +1,42 @@
|
|
|
+worker_processes auto;
|
|
|
+
|
|
|
+events {
|
|
|
+ worker_connections 1024;
|
|
|
+}
|
|
|
+
|
|
|
+http {
|
|
|
+ include mime.types;
|
|
|
+
|
|
|
+ default_type application/octet-stream;
|
|
|
+
|
|
|
+ sendfile on;
|
|
|
+
|
|
|
+ keepalive_timeout 65;
|
|
|
+
|
|
|
+ client_max_body_size 20m;
|
|
|
+
|
|
|
+ server {
|
|
|
+ listen 80;
|
|
|
+ server_name localhost;
|
|
|
+
|
|
|
+ gzip on;
|
|
|
+ gzip_min_length 1k;
|
|
|
+ gzip_comp_level 9;
|
|
|
+ gzip_types text/plain application/javascript application/x-javascript text/css application/xml text/javascript application/x-httpd-php image/jpeg image/gif image/png;
|
|
|
+ gzip_vary on;
|
|
|
+
|
|
|
+ location / {
|
|
|
+ root /usr/share/nginx/html;
|
|
|
+ try_files $uri $uri/ @router;
|
|
|
+ index index.html index.htm;
|
|
|
+ error_page 405 =200 http://$host$request_uri;
|
|
|
+ }
|
|
|
+ location @router {
|
|
|
+ rewrite ^.*$ /index.html last;
|
|
|
+ }
|
|
|
+ error_page 500 502 503 504 /50x.html;
|
|
|
+ location = /50x.html {
|
|
|
+ root html;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|