ngingx_vhost_default.tpl 990 B

1234567891011121314151617181920212223242526272829303132333435
  1. server {
  2. listen %ip%:%proxy_port%;
  3. server_name %domain_idn% %alias_idn%;
  4. server_name_in_redirect off;
  5. %elog%error_log /var/log/httpd/domains/%domain%.error.log error;
  6. location / {
  7. proxy_pass http://%ip%:%web_port%;
  8. location ~* ^.+\.(%extentions%)$ {
  9. root %docroot%;
  10. access_log /var/log/httpd/domains/%domain%.log combined;
  11. access_log /var/log/httpd/domains/%domain%.bytes bytes;
  12. expires max;
  13. try_files $uri @fallback;
  14. }
  15. }
  16. location /error/ {
  17. alias %home%/%user%/web/%domain%/document_errors/;
  18. }
  19. location @fallback {
  20. proxy_pass http://%ip%:%web_port%;
  21. }
  22. location ~ /\.ht {return 404;}
  23. location ~ /\.svn/ {return 404;}
  24. location ~ /\.git/ {return 404;}
  25. location ~ /\.hg/ {return 404;}
  26. location ~ /\.bzr/ {return 404;}
  27. include %home%/%user%/conf/nginx.%domain%.conf*;
  28. }