config.conf 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. user nginx;
  2. worker_processes auto;
  3. error_log /var/log/nginx/error.log warn;
  4. pid /var/run/nginx.pid;
  5. events {
  6. worker_connections 1024;
  7. }
  8. http {
  9. include /etc/nginx/mime.types;
  10. default_type application/octet-stream;
  11. log_format main '$remote_addr - $remote_user [$time_local] "$request" '
  12. '$status $body_bytes_sent "$http_referer" '
  13. '"$http_user_agent" "$http_x_forwarded_for"';
  14. client_max_body_size 1000m;
  15. client_body_buffer_size 600m;
  16. client_header_buffer_size 8m;
  17. access_log /var/log/nginx/access.log main;
  18. sendfile on;
  19. keepalive_timeout 65;
  20. gzip_static on;
  21. #include /etc/nginx/conf.d/*.conf;
  22. server {
  23. listen 80;
  24. server_name localhost;
  25. access_log /var/log/nginx/host.access.log main;
  26. error_log /var/log/nginx/error.log error;
  27. location / {
  28. root /usr/share/nginx/html;
  29. index index.html index.htm;
  30. error_page 405 =200 $request_uri;
  31. }
  32. location /api56/open/common/ {
  33. proxy_pass http://gatewayservice:10001/open/common/;
  34. proxy_redirect off;
  35. proxy_set_header Host $host;
  36. }
  37. location /api56/ {
  38. proxy_pass http://gatewayservice:10001/transfer/manage/;
  39. proxy_redirect off;
  40. proxy_set_header Host $host;
  41. #location ~ .*ping?$ {
  42. # return 404;
  43. #}
  44. #if ($request_uri ~* ^/\?ping(.*)$) {
  45. # return 404;
  46. #}
  47. }
  48. error_page 500 502 503 504 /50x.html;
  49. location = /50x.html {
  50. root /usr/share/nginx/html;
  51. }
  52. #location ~ .*ping?$ {
  53. # return 404;
  54. #}
  55. #if ($request_uri ~* ^/\?ping(.*)$) {
  56. # return 404;
  57. #}
  58. }
  59. }