Advertisement
Guest User

Untitled

a guest
Dec 8th, 2021
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.36 KB | None | 0 0
  1. <VirtualHost *:80>
  2.  
  3. ServerName mail.x
  4.  
  5. ServerAlias autodiscover.*
  6. ServerAlias autoconfig.*
  7. RewriteEngine on
  8.  
  9. RewriteCond %{HTTPS} off
  10. RewriteRule ^/?(.*) https://%{HTTP_HOST}/$1 [R=301,L]
  11.  
  12.  
  13. ProxyPass / http://127.0.0.1:8080/
  14.  
  15. ProxyPassReverse / http://127.0.0.1:8080/
  16.  
  17. ProxyPreserveHost On
  18. ProxyAddHeaders On
  19. RequestHeader set X-Forwarded-Proto "http"
  20. </VirtualHost>
  21. <VirtualHost *:443>
  22.  
  23. ServerName mail.x
  24.  
  25. ServerAlias autodiscover.*
  26. ServerAlias autoconfig.*
  27.  
  28. # You should proxy to a plain HTTP session to offload SSL processing
  29.  
  30. ProxyPass /Microsoft-Server-ActiveSync http://127.0.0.1:8080/Microsoft-Server-ActiveSync connectiontimeout=4000
  31.  
  32. ProxyPassReverse /Microsoft-Server-ActiveSync http://127.0.0.1:8080/Microsoft-Server-ActiveSync
  33.  
  34. ProxyPass / http://127.0.0.1:8080/
  35.  
  36. ProxyPassReverse / http://127.0.0.1:8080/
  37.  
  38. ProxyPreserveHost On
  39. ProxyAddHeaders On
  40. RequestHeader set X-Forwarded-Proto "https"
  41.  
  42.  
  43. SSLCertificateFile opt/mailcow-dockerized/data/assets/ssl/cert.pem
  44.  
  45. SSLCertificateKeyFile opt/mailcow-dockerized/data/assets/ssl/key.pem
  46.  
  47.  
  48. # If you plan to proxy to a HTTPS host:
  49. #SSLProxyEngine On
  50.  
  51. # If you plan to proxy to an untrusted HTTPS host:
  52. #SSLProxyVerify none
  53. #SSLProxyCheckPeerCN off
  54. #SSLProxyCheckPeerName off
  55. #SSLProxyCheckPeerExpire off
  56. </VirtualHost>
  57.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement