nginx.conf 641 B

123456789101112131415161718192021222324
  1. server {
  2. listen 80;
  3. server_name _;
  4. # gzip config
  5. gzip on;
  6. gzip_min_length 1k;
  7. gzip_comp_level 6;
  8. gzip_types text/plain text/css text/javascript application/json application/javascript application/x-javascript application/xml;
  9. gzip_vary on;
  10. gzip_disable "MSIE [1-6]\.";
  11. root /usr/share/nginx/html;
  12. include /etc/nginx/mime.types;
  13. location / {
  14. try_files $uri $uri/ /index.html;
  15. }
  16. # location /api {
  17. # proxy_pass https://preview.pro.antdv.com/api;
  18. # proxy_set_header X-Forwarded-Proto $scheme;
  19. # proxy_set_header X-Real-IP $remote_addr;
  20. # }
  21. }