.example.proxy.conf 883 B

1234567891011121314151617181920212223242526272829303132
  1. #PROXY-START/
  2. location ~* \.(php|jsp|cgi|asp|aspx)$
  3. {
  4. proxy_pass http://127.0.0.1:21919;
  5. proxy_set_header Host $host;
  6. proxy_set_header X-Real-IP $remote_addr;
  7. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  8. proxy_set_header REMOTE-HOST $remote_addr;
  9. }
  10. location /
  11. {
  12. if (!-e $request_filename) {
  13. proxy_pass http://127.0.0.1:21919;
  14. }
  15. proxy_http_version 1.1;
  16. proxy_read_timeout 360s;
  17. proxy_redirect off;
  18. proxy_set_header Upgrade $http_upgrade;
  19. proxy_set_header Connection "upgrade";
  20. proxy_set_header Host $host;
  21. proxy_set_header X-Real-IP $remote_addr;
  22. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  23. proxy_set_header REMOTE-HOST $remote_addr;
  24. add_header X-Cache $upstream_cache_status;
  25. #Set Nginx Cache
  26. add_header Cache-Control no-cache;
  27. expires 12h;
  28. }
  29. #PROXY-END/