bm39.eu in unique macro-file, /.well-known moved to global alias config
This commit is contained in:
74
damia/etc/apache2/sites-available/eu.bm39-all.conf
Normal file
74
damia/etc/apache2/sites-available/eu.bm39-all.conf
Normal file
@@ -0,0 +1,74 @@
|
||||
# all bm39.eu subdomains
|
||||
|
||||
<Macro bm39 $name $domain>
|
||||
<VirtualHost *:80>
|
||||
ServerName $domain
|
||||
ServerAlias www.$domain
|
||||
UseCanonicalName Off
|
||||
|
||||
#DocumentRoot /home/www/eu.bm39/$name
|
||||
|
||||
CustomLog ${APACHE_LOG_DIR}/eu.bm39.$name-access.log combined
|
||||
ErrorLog ${APACHE_LOG_DIR}/eu.bm39.$name-error.log
|
||||
|
||||
# br, feb 13, 2016. The following hack is necessary to have
|
||||
# letsencrypt work in "--webroot" mode, as it does not handle
|
||||
# https redirection
|
||||
RewriteEngine On
|
||||
RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge [NC]
|
||||
RewriteRule ^(.*)$ https://%{HTTP_HOST}$1 [R=301,L]
|
||||
</VirtualHost>
|
||||
|
||||
<VirtualHost *:443>
|
||||
ServerName $domain
|
||||
ServerAlias www.$domain
|
||||
UseCanonicalName Off
|
||||
|
||||
DocumentRoot /home/www/eu.bm39/$name
|
||||
|
||||
CustomLog ${APACHE_LOG_DIR}/eu.bm39.$name-access.log combined
|
||||
ErrorLog ${APACHE_LOG_DIR}/eu.bm39.$name-error.log
|
||||
|
||||
SSLEngine on
|
||||
SSLCertificateFile /etc/letsencrypt/live/bm39.eu/fullchain.pem
|
||||
SSLCertificateKeyFile /etc/letsencrypt/live/bm39.eu/privkey.pem
|
||||
|
||||
<Location />
|
||||
SSLRequireSSL On
|
||||
SSLVerifyClient none
|
||||
SSLVerifyDepth 1
|
||||
SSLOptions +StdEnvVars +StrictRequire
|
||||
</Location>
|
||||
|
||||
RewriteEngine on
|
||||
|
||||
<Directory /home/www/eu.bm39/$name>
|
||||
Options Indexes FollowSymLinks MultiViews
|
||||
AllowOverride All
|
||||
Require all granted
|
||||
# Kesako ?
|
||||
SSLRenegBufferSize 10486000
|
||||
</Directory>
|
||||
|
||||
# Kesako ?
|
||||
<IfModule mod_headers.c>
|
||||
Header always set Strict-Transport-Security "max-age=15768000; includeSubDomains; preload"
|
||||
</IfModule>
|
||||
|
||||
# Kesako ? Puisque mod_security2 n'est pas utilisé, je commente.
|
||||
#<IfModule mod_security2.c>
|
||||
# SecRequestBodyNoFilesLimit 5242880
|
||||
#</IfModule>
|
||||
|
||||
</VirtualHost>
|
||||
|
||||
</Macro>
|
||||
|
||||
# macros: Each line is
|
||||
# Use <dir> <fqdn>
|
||||
# with dir: /home/www/eu.bm39/<dir>
|
||||
Use bm39 root bm39.eu
|
||||
Use bm39 dev dev.bm39.eu
|
||||
Use bm39 test test.bm39.eu
|
||||
|
||||
UndefMacro bm39
|
Reference in New Issue
Block a user