nginx-debug-http.conf 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. user nginx;
  2. worker_processes 1;
  3. error_log /var/error.log info;
  4. worker_rlimit_nofile 1024;
  5. events {
  6. worker_connections 1024;
  7. }
  8. http
  9. {
  10. include mime.types;
  11. default_type application/octet-stream;
  12. fastcgi_buffer_size 32k;
  13. fastcgi_buffers 8 32k;
  14. underscores_in_headers on;
  15. client_max_body_size 1024M;
  16. sendfile on;
  17. keepalive_timeout 65;
  18. log_format main '$remote_addr - $remote_user [$time_local] "$request" '
  19. '$status $body_bytes_sent "$http_referer" '
  20. '"$http_user_agent" "$http_x_forwarded_for"';
  21. server
  22. {
  23. listen 80;
  24. set $folder_name /var/www/html;
  25. server_name 192.168.1.220;
  26. root $folder_name;
  27. index index.html index.php;
  28. client_max_body_size 100m;
  29. proxy_connect_timeout 500s;
  30. proxy_read_timeout 500s;
  31. proxy_send_timeout 500s;
  32. fastcgi_connect_timeout 75;
  33. fastcgi_read_timeout 600;
  34. fastcgi_send_timeout 600;
  35. charset utf-8;
  36. location /logs {
  37. deny all;
  38. return 403;
  39. }
  40. location /data/log {
  41. deny all;
  42. return 403;
  43. }
  44. location / {
  45. index index.html index.htm index.php;
  46. }
  47. location /mshop {
  48. root $folder_name;
  49. autoindex on;
  50. index index.html index.htm index.php;
  51. try_files $uri $uri/ /mshop/index.html;
  52. }
  53. location ~ /mobile/[/\w]+\.php$ {
  54. root $folder_name;
  55. fastcgi_pass host.docker.internal:9100;
  56. fastcgi_index index.php;
  57. fastcgi_param SCRIPT_FILENAME $folder_name$fastcgi_script_name;
  58. include fastcgi_params;
  59. }
  60. location ~ /mobile/[/\w]+\.html$ {
  61. try_files $uri $uri/ /mobile/index.html;
  62. }
  63. location ~ /racc/[/\w]+\.php$ {
  64. root $folder_name;
  65. fastcgi_pass host.docker.internal:9101;
  66. fastcgi_index index.php;
  67. fastcgi_param SCRIPT_FILENAME $folder_name$fastcgi_script_name;
  68. include fastcgi_params;
  69. }
  70. location ~ \.php$ {
  71. add_header Cache-Control no-store;
  72. root $folder_name;
  73. fastcgi_pass websrv:9000;
  74. fastcgi_index index.php;
  75. fastcgi_param SCRIPT_FILENAME $folder_name$fastcgi_script_name;
  76. include fastcgi_params;
  77. }
  78. }
  79. }