maverick78

nginx.conf

Mar 21st, 2012
79
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. user nginx;
  2. worker_processes 2;
  3. pid /var/run/nginx.pid;
  4.  
  5. events {
  6. worker_connections 64;
  7. }
  8.  
  9. http {
  10. ##
  11. # General settings and defaults
  12. ##
  13.  
  14. server_tokens off;
  15. default_type application/octet-stream;
  16. charset utf-8;
  17. ignore_invalid_headers on;
  18. recursive_error_pages on;
  19. source_charset utf-8;
  20. sendfile on;
  21. tcp_nopush on;
  22. tcp_nodelay on;
  23. max_ranges 0;
  24. server_names_hash_bucket_size 64;
  25. server_names_hash_max_size 512;
  26.  
  27. include /etc/nginx/mime.types;
  28.  
  29. ##
  30. # Logging Settings
  31. ##
  32.  
  33. access_log /var/log/nginx/access.log;
  34. error_log /var/log/nginx/error.log debug;
  35.  
  36. ##
  37. # Limits
  38. ##
  39.  
  40. client_body_buffer_size 1K;
  41. client_header_buffer_size 1k;
  42. client_max_body_size 1k;
  43. large_client_header_buffers 2 1k;
  44.  
  45. ##
  46. # Timeouts
  47. ##
  48.  
  49. client_body_timeout 10;
  50. client_header_timeout 10;
  51. keepalive_timeout 5 5;
  52. send_timeout 10;
  53.  
  54. ##
  55. # Gzip Settings
  56. ##
  57.  
  58. gzip on;
  59. #gzip_static on;
  60.  
  61. gzip_vary on;
  62. gzip_disable "msie6";
  63. gzip_proxied any;
  64. gzip_comp_level 6;
  65. gzip_buffers 16 8k;
  66. gzip_http_version 1.1;
  67. gzip_types text/plain text/css text/javascript image/jpeg image/png image/x-icon;
  68.  
  69. ##
  70. # Pass php-files to php-fpm
  71. ##
  72.  
  73. upstream php {
  74. server unix:/var/run/www.sock;
  75. }
  76.  
  77. ##
  78. # Virtual Host Configs
  79. ##
  80.  
  81. include /etc/nginx/conf.d/*.conf;
  82. include /etc/nginx/sites-enabled/*;
  83. }
RAW Paste Data