Advertisement
lanceq

Untitled

Apr 17th, 2014
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.56 KB | None | 0 0
  1.  
  2. user www-data;
  3. worker_processes 6;
  4.  
  5. #error_log logs/error.log;
  6. #error_log logs/error.log notice;
  7. #error_log logs/error.log info;
  8.  
  9. #pid logs/nginx.pid;
  10.  
  11.  
  12. events {
  13. worker_connections 1024;
  14. multi_accept on;
  15. }
  16.  
  17.  
  18. http {
  19. include mime.types;
  20. default_type application/octet-stream;
  21.  
  22. #log_format main '$remote_addr - $remote_user [$time_local] "$request" '
  23. # '$status $body_bytes_sent "$http_referer" '
  24. # '"$http_user_agent" "$http_x_forwarded_for"';
  25.  
  26. #access_log logs/access.log main;
  27.  
  28. sendfile on;
  29. tcp_nopush on;
  30. tcp_nodelay on;
  31.  
  32. #keepalive_timeout 0;
  33. keepalive_timeout 2;
  34.  
  35. # Gzip Settings
  36.  
  37. gzip on;
  38. gzip_static on;
  39. gzip_disable "msie6";
  40. gzip_http_version 1.1;
  41. gzip_comp_level 6;
  42. gzip_proxied any;
  43. gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript application/javascript text/x-js;
  44. gzip_buffers 16 8k;
  45.  
  46. # File Cache Settings
  47.  
  48. open_file_cache max=5000 inactive=20s;
  49. open_file_cache_valid 30s;
  50. open_file_cache_min_uses 2;
  51. open_file_cache_errors on;
  52.  
  53.  
  54.  
  55. server {
  56. listen 80;
  57. server_name localhost;
  58.  
  59. #charset koi8-r;
  60.  
  61. #access_log logs/host.access.log main;
  62.  
  63. location / {
  64. root html;
  65. index index.html index.htm;
  66. }
  67.  
  68. location ~* \.(jpg|jpeg|png|gif|ico)$ {
  69. log_not_found off;
  70. access_log off;
  71. }
  72.  
  73. #error_page 404 /404.html;
  74.  
  75. # redirect server error pages to the static page /50x.html
  76. #
  77. error_page 500 502 503 504 /50x.html;
  78. location = /50x.html {
  79. root html;
  80. }
  81.  
  82. # proxy the PHP scripts to Apache listening on 127.0.0.1:80
  83. #
  84. #location ~ \.php$ {
  85. # proxy_pass http://127.0.0.1;
  86. #}
  87.  
  88. # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
  89. #
  90. #location ~ \.php$ {
  91. # root html;
  92. # fastcgi_pass 127.0.0.1:9000;
  93. # fastcgi_index index.php;
  94. # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
  95. # include fastcgi_params;
  96. #}
  97.  
  98. # deny access to .htaccess files, if Apache's document root
  99. # concurs with nginx's one
  100. #
  101. #location ~ /\.ht {
  102. # deny all;
  103. #}
  104. }
  105.  
  106.  
  107. # another virtual host using mix of IP-, name-, and port-based configuration
  108. #
  109. #server {
  110. # listen 8000;
  111. # listen somename:8080;
  112. # server_name somename alias another.alias;
  113.  
  114. # location / {
  115. # root html;
  116. # index index.html index.htm;
  117. # }
  118. #}
  119.  
  120.  
  121. # HTTPS server
  122. #
  123. #server {
  124. # listen 443;
  125. # server_name localhost;
  126.  
  127. # ssl on;
  128. # ssl_certificate cert.pem;
  129. # ssl_certificate_key cert.key;
  130.  
  131. # ssl_session_timeout 5m;
  132.  
  133. # ssl_protocols SSLv2 SSLv3 TLSv1;
  134. # ssl_ciphers HIGH:!aNULL:!MD5;
  135. # ssl_prefer_server_ciphers on;
  136.  
  137. # location / {
  138. # root html;
  139. # index index.html index.htm;
  140. # }
  141. #}
  142. include /etc/nginx/sites-enabled/*;
  143.  
  144. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement