You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
2.3 KiB

6 years ago
6 years ago
  1. location / {
  2. rewrite ^/.*$ /index.php last;
  3. }
  4. location ~ ^/combine.*\.(css|js) {
  5. rewrite ^/.*$ /index.php last;
  6. expires max;
  7. }
  8. # Whitelist
  9. ## Let October handle if static file not exists
  10. location ~ ^/favicon\.ico { try_files $uri /index.php; }
  11. location ~ ^/sitemap\.xml { try_files $uri /index.php; }
  12. location ~ ^/robots\.txt { try_files $uri /index.php; }
  13. location ~ ^/humans\.txt { try_files $uri /index.php; }
  14. ## Let nginx return 404 if static file not exists
  15. location ~ ^/storage/app/uploads/public { try_files $uri 404; }
  16. location ~ ^/storage/app/media { try_files $uri 404; }
  17. location ~ ^/storage/temp/public { try_files $uri 404; }
  18. location ~ ^/modules/.*/assets { try_files $uri 404; }
  19. location ~ ^/modules/.*/resources { try_files $uri 404; }
  20. location ~ ^/modules/.*/behaviors/.*/assets { try_files $uri 404; }
  21. location ~ ^/modules/.*/behaviors/.*/resources { try_files $uri 404; }
  22. location ~ ^/modules/.*/widgets/.*/assets { try_files $uri 404; }
  23. location ~ ^/modules/.*/widgets/.*/resources { try_files $uri 404; }
  24. location ~ ^/modules/.*/formwidgets/.*/assets { try_files $uri 404; }
  25. location ~ ^/modules/.*/formwidgets/.*/resources { try_files $uri 404; }
  26. location ~ ^/modules/.*/reportwidgets/.*/assets { try_files $uri 404; }
  27. location ~ ^/modules/.*/reportwidgets/.*/resources { try_files $uri 404; }
  28. location ~ ^/plugins/.*/.*/assets { try_files $uri 404; }
  29. location ~ ^/plugins/.*/.*/resources { try_files $uri 404; }
  30. location ~ ^/plugins/.*/.*/behaviors/.*/assets { try_files $uri 404; }
  31. location ~ ^/plugins/.*/.*/behaviors/.*/resources { try_files $uri 404; }
  32. location ~ ^/plugins/.*/.*/reportwidgets/.*/assets { try_files $uri 404; }
  33. location ~ ^/plugins/.*/.*/reportwidgets/.*/resources { try_files $uri 404; }
  34. location ~ ^/plugins/.*/.*/formwidgets/.*/assets { try_files $uri 404; }
  35. location ~ ^/plugins/.*/.*/formwidgets/.*/resources { try_files $uri 404; }
  36. location ~ ^/plugins/.*/.*/widgets/.*/assets { try_files $uri 404; }
  37. location ~ ^/plugins/.*/.*/widgets/.*/resources { try_files $uri 404; }
  38. location ~ ^/themes/.*/assets { try_files $uri 404; }
  39. location ~ ^/themes/.*/semantic { try_files $uri 404; }
  40. location ~ ^/themes/.*/resources { try_files $uri 404; }