21 lines
578 B
Plaintext
21 lines
578 B
Plaintext
|
# VMailHTTPS for roundcubemail webmail at mail. subdomain assumes & requires https w/ valid cert
|
||
|
|
||
|
# Webmail - HTTP Port 80 Redirects to HTTPS Port 443
|
||
|
<Macro VMailHTTPS $vhost>
|
||
|
<VirtualHost *:80>
|
||
|
ServerName $vhost
|
||
|
<Location "/">
|
||
|
<If "%{REQUEST_URI} !~ m#^/.well-known/acme-challenge/#">
|
||
|
Redirect / https://$vhost
|
||
|
</If>
|
||
|
</Location>
|
||
|
</VirtualHost>
|
||
|
<VirtualHost *:443>
|
||
|
ServerName $vhost
|
||
|
DocumentRoot /srv/www/html/roundcubemail/
|
||
|
SSLEngine on
|
||
|
SSLCertificateFile /etc/ssl/letsencrypt/$vhost.pem
|
||
|
</VirtualHost>
|
||
|
</Macro>
|
||
|
|