ngx_dev_config 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. #upstream rungobackend {
  2. # server 127.0.0.1:28889;
  3. # keepalive 128;
  4. #}
  5. server {
  6. listen 80;
  7. server_name tfohowapi.hiwavo.com;
  8. charset utf-8;
  9. access_log /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/logs/ngx_access.log main;
  10. error_log /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/logs/ngx_error.log;
  11. location /.well-known/pki-validation/ {
  12. alias /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/static/tapi/;
  13. }
  14. location =/MP_verify_WKpffc3SRB4yjEzI.txt {
  15. root /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/static/tapi/;
  16. #expires 30d;
  17. }
  18. location =/stcXSY70Qh.txt {
  19. root /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/static/tapi/;
  20. #expires 30d;
  21. }
  22. location / {
  23. proxy_next_upstream off;
  24. proxy_set_header X-Real-IP $remote_addr;
  25. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  26. proxy_set_header Host $host;
  27. proxy_http_version 1.1;
  28. proxy_set_header Connection "";
  29. proxy_pass http://127.0.0.1:25565;
  30. }
  31. location /ngx {
  32. stub_status on;
  33. }
  34. }
  35. # HTTPS server
  36. server {
  37. listen 443 ssl;
  38. server_name tfohowapi.hiwavo.com;
  39. charset utf-8;
  40. #ssl on;
  41. ssl_certificate /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/static/tapi/tfohowapi.hiwavo.com.pem;
  42. ssl_certificate_key /root/sites/fohow_git/x_api/go/gopath/src/fohow.com/static/tapi/tfohowapi.hiwavo.com.key;
  43. ssl_session_cache shared:SSL:1m;
  44. ssl_session_timeout 5m;
  45. ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE:ECDH:AES:HIGH:!NULL:!aNULL:!MD5:!ADH:!RC4;
  46. ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
  47. ssl_prefer_server_ciphers on;
  48. location / {
  49. proxy_next_upstream off;
  50. proxy_set_header X-Real-IP $remote_addr;
  51. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  52. proxy_set_header Host $host;
  53. proxy_http_version 1.1;
  54. proxy_set_header Connection "";
  55. proxy_pass http://tfohowapi.hiwavo.com:80;
  56. }
  57. }