nginx-debug-http.conf 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. user nginx;
  2. worker_processes 1;
  3. error_log /var/error.log info;
  4. #pid logs/nginx.pid;
  5. worker_rlimit_nofile 1024;
  6. events {
  7. worker_connections 1024;
  8. }
  9. http
  10. {
  11. include mime.types;
  12. default_type application/octet-stream;
  13. fastcgi_buffer_size 32k;
  14. fastcgi_buffers 8 32k;
  15. underscores_in_headers on;
  16. client_max_body_size 1024M;
  17. sendfile on;
  18. keepalive_timeout 65;
  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"';
  22. server
  23. {
  24. listen 8080;
  25. set $folder_name /var/www/html/public;
  26. server_name 192.168.1.200;
  27. root $folder_name;
  28. index index.html index.php;
  29. client_max_body_size 100m;
  30. proxy_connect_timeout 500s;
  31. proxy_read_timeout 500s;
  32. proxy_send_timeout 500s;
  33. fastcgi_connect_timeout 75;
  34. fastcgi_read_timeout 600;
  35. fastcgi_send_timeout 600;
  36. charset utf-8;
  37. location /logs {
  38. deny all;
  39. return 403;
  40. }
  41. location /data/log {
  42. deny all;
  43. return 403;
  44. }
  45. location / {
  46. index index.html index.htm index.php;
  47. }
  48. location /mshop {
  49. root $folder_name;
  50. autoindex on;
  51. index index.html index.htm index.php;
  52. try_files $uri $uri/ /mshop/index.html;
  53. }
  54. location ~ \.php$ {
  55. add_header Cache-Control no-store;
  56. root $folder_name;
  57. fastcgi_pass devfpm:9000;
  58. fastcgi_index index.php;
  59. fastcgi_param SCRIPT_FILENAME $folder_name$fastcgi_script_name;
  60. include fastcgi_params;
  61. }
  62. }
  63. }