omnireader_http 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. server {
  2. listen 80;
  3. server_name omnireader.ru;
  4. client_max_body_size 50m;
  5. proxy_read_timeout 1h;
  6. gzip on;
  7. gzip_min_length 1024;
  8. gzip_proxied expired no-cache no-store private auth;
  9. gzip_types *;
  10. location /api {
  11. proxy_pass http://127.0.0.1:44081;
  12. }
  13. location /ws {
  14. proxy_pass http://127.0.0.1:44081;
  15. proxy_http_version 1.1;
  16. proxy_set_header Upgrade $http_upgrade;
  17. proxy_set_header Connection "upgrade";
  18. }
  19. location / {
  20. root /home/liberama/public;
  21. location /tmp {
  22. add_header Content-Type text/xml;
  23. add_header Content-Encoding gzip;
  24. }
  25. location ~* \.(?:manifest|appcache|html)$ {
  26. expires -1;
  27. }
  28. }
  29. }
  30. server {
  31. listen 80;
  32. server_name old.omnireader.ru;
  33. client_max_body_size 50m;
  34. gzip on;
  35. gzip_min_length 1024;
  36. gzip_proxied expired no-cache no-store private auth;
  37. gzip_types *;
  38. root /home/oldreader;
  39. index index.html;
  40. # Обработка php файлов с помощью fpm
  41. location ~ \.php$ {
  42. try_files $uri =404;
  43. include /etc/nginx/fastcgi.conf;
  44. fastcgi_pass unix:/run/php/php7.2-fpm.sock;
  45. }
  46. }