no-php.stpl 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. server {
  2. listen %ip%:%web_ssl_port%;
  3. server_name %domain_idn% %alias_idn%;
  4. root %sdocroot%;
  5. index index.php index.html index.htm;
  6. access_log /var/log/nginx/domains/%domain%.log combined;
  7. access_log /var/log/nginx/domains/%domain%.bytes bytes;
  8. error_log /var/log/nginx/domains/%domain%.error.log error;
  9. ssl on;
  10. ssl_certificate %ssl_pem%;
  11. ssl_certificate_key %ssl_key%;
  12. types {
  13. text/html html htm shtml php php5;
  14. }
  15. location / {
  16. location ~* ^.+\.(jpeg|jpg|png|gif|bmp|ico|svg|css|js)$ {
  17. expires max;
  18. }
  19. }
  20. error_page 403 /error/404.html;
  21. error_page 404 /error/404.html;
  22. error_page 500 502 503 504 /error/50x.html;
  23. location /error/ {
  24. alias %home%/%user%/web/%domain%/document_errors/;
  25. }
  26. location ~* "/\.(htaccess|htpasswd)$" {
  27. deny all;
  28. return 404;
  29. }
  30. include /etc/nginx/conf.d/phpmyadmin.inc*;
  31. include /etc/nginx/conf.d/phppgadmin.inc*;
  32. include /etc/nginx/conf.d/webmail.inc*;
  33. include %home%/%user%/conf/web/snginx.%domain%.conf*;
  34. }