Advertisement
Twissel

SSL_Webmail

May 2nd, 2019
708
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.37 KB | None | 0 0
  1. server {
  2. listen 178.128.206.221:443 ssl http2;
  3. server_name webmail.origammi.tk mail.origammi.tk;
  4. ssl_certificate /home/admin/conf/mail/origammi.tk/ssl/origammi.tk.pem;
  5. ssl_certificate_key /home/admin/conf/mail/origammi.tk/ssl/origammi.tk.key;
  6. root /var/lib/roundcube;
  7. index index.php;
  8.  
  9. location ~ /(config|temp|logs) {
  10. deny all;
  11. return 404;
  12. }
  13.  
  14. location ~ /\.(?!well-known\/) {
  15. deny all;
  16. return 404;
  17. }
  18.  
  19. location / {
  20. try_files $uri $uri/ /index.php?$args;
  21. location ~* ^.+\.(ogg|ogv|svg|svgz|swf|eot|otf|woff|mov|mp3|mp4|webm|flv|ttf|rss|atom|jpg|jpeg|gif|png|ico|bmp|mid|midi|wav|rtf|css|js|jar)$ {
  22. alias /var/lib/roundcube/;
  23. expires 1h;
  24. fastcgi_hide_header "Set-Cookie";
  25. }
  26. }
  27.  
  28. location ~ ^/(.*\.php)$ {
  29. alias /var/lib/roundcube/$1;
  30. fastcgi_pass 127.0.0.1:9000;
  31. fastcgi_index index.php;
  32. include fastcgi_params;
  33. fastcgi_param SCRIPT_FILENAME $request_filename;
  34. }
  35.  
  36. error_page 403 /error/404.html;
  37. error_page 404 /error/404.html;
  38. error_page 500 502 503 504 /error/50x.html;
  39.  
  40. location /error/ {
  41. alias /home/admin/web/origammi.tk/document_errors/;
  42. }
  43.  
  44. include /home/admin/conf/mail/origammi.tk/nginx.conf_*;
  45. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement