changement macro checkmaintenance
This commit is contained in:
parent
2f173e2335
commit
cdab61bf56
2 changed files with 7 additions and 12 deletions
|
@ -106,7 +106,7 @@
|
||||||
#RewriteRule .* ws://%{SERVER_NAME}%{REQUEST_URI} [P,QSA,L]
|
#RewriteRule .* ws://%{SERVER_NAME}%{REQUEST_URI} [P,QSA,L]
|
||||||
## Soit parce que l'url demandée est d'une forme qui permet de détecter que le client s'adresse à une partie serveur développée avec des websockets
|
## Soit parce que l'url demandée est d'une forme qui permet de détecter que le client s'adresse à une partie serveur développée avec des websockets
|
||||||
#<Location /websockify>
|
#<Location /websockify>
|
||||||
# ProxyPass ws://$urlDest/websockify
|
# ProxyPass ws://${URL_DEST}/websockify
|
||||||
# ProxyPassReverse ws://$vhostFQDN/websockify
|
# ProxyPassReverse ws://${VHOST_FQDN}/websockify
|
||||||
#</Location>
|
#</Location>
|
||||||
|
|
||||||
|
|
|
@ -170,7 +170,7 @@ SecCookieFormat 0
|
||||||
</Macro>
|
</Macro>
|
||||||
|
|
||||||
|
|
||||||
<Macro CheckMaintenancePage>
|
<Macro CheckMaintenancePage $vhostFQDN>
|
||||||
RewriteEngine On
|
RewriteEngine On
|
||||||
|
|
||||||
<Location "/rp_maintenance/auth/">
|
<Location "/rp_maintenance/auth/">
|
||||||
|
@ -178,12 +178,12 @@ SecCookieFormat 0
|
||||||
</Location>
|
</Location>
|
||||||
|
|
||||||
# Si on est en maintenance
|
# Si on est en maintenance
|
||||||
<If "-f %{DOCUMENT_ROOT} . '/maintenance/${VHOST_FQDN}'">
|
<If "-f %{DOCUMENT_ROOT} . '/maintenance/$vhostFQDN'">
|
||||||
RewriteCond %{REMOTE_ADDR} !127.0.0.1
|
RewriteCond %{REMOTE_ADDR} !127.0.0.1
|
||||||
RewriteCond %{REQUEST_URI} !^/rp_ressources/*
|
RewriteCond %{REQUEST_URI} !^/rp_ressources/*
|
||||||
RewriteCond %{REQUEST_URI} !^/rp_maintenance/*
|
RewriteCond %{REQUEST_URI} !^/rp_maintenance/*
|
||||||
RewriteCond %{HTTP_COOKIE} !rp_acces_maintenance=([^;]+)
|
RewriteCond %{HTTP_COOKIE} !rp_acces_maintenance=([^;]+)
|
||||||
RewriteRule ^.*$ %{DOCUMENT_ROOT}/maintenance/${VHOST_FQDN}
|
RewriteRule ^.*$ %{DOCUMENT_ROOT}/maintenance/$vhostFQDN
|
||||||
Header Set Cache-Control "no-store"
|
Header Set Cache-Control "no-store"
|
||||||
</If>
|
</If>
|
||||||
</Macro>
|
</Macro>
|
||||||
|
@ -219,8 +219,6 @@ SecCookieFormat 0
|
||||||
<Macro vhost_HTTPS_Generic $vhostFQDN $cert $protoDest $urlDest $logPolicy $accessPolicy $indexingConf $modsecurityStatus>
|
<Macro vhost_HTTPS_Generic $vhostFQDN $cert $protoDest $urlDest $logPolicy $accessPolicy $indexingConf $modsecurityStatus>
|
||||||
Use vhost_redirect_http-https $vhostFQDN
|
Use vhost_redirect_http-https $vhostFQDN
|
||||||
|
|
||||||
Define VHOST_FQDN $vhostFQDN
|
|
||||||
|
|
||||||
<Perl>
|
<Perl>
|
||||||
if ( $cert eq "LE" )
|
if ( $cert eq "LE" )
|
||||||
{
|
{
|
||||||
|
@ -297,7 +295,7 @@ Define VHOST_FQDN $vhostFQDN
|
||||||
Use ErrorDocumentPages
|
Use ErrorDocumentPages
|
||||||
|
|
||||||
# Gestion de la page de maintenance
|
# Gestion de la page de maintenance
|
||||||
Use CheckMaintenancePage
|
Use CheckMaintenancePage $vhostFQDN
|
||||||
|
|
||||||
# Gestion mod_security et inclusion des exceptions
|
# Gestion mod_security et inclusion des exceptions
|
||||||
<IfModule mod_security2.c>
|
<IfModule mod_security2.c>
|
||||||
|
@ -318,7 +316,6 @@ Define VHOST_FQDN $vhostFQDN
|
||||||
</Perl>
|
</Perl>
|
||||||
|
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
Undefine VHOST_FQDN
|
|
||||||
</Macro>
|
</Macro>
|
||||||
|
|
||||||
|
|
||||||
|
@ -326,7 +323,6 @@ Undefine VHOST_FQDN
|
||||||
|
|
||||||
<Macro vhost_HTTP_Generic $vhostFQDN $protoDest $urlDest $logPolicy $accessPolicy $indexingConf $modsecurityStatus>
|
<Macro vhost_HTTP_Generic $vhostFQDN $protoDest $urlDest $logPolicy $accessPolicy $indexingConf $modsecurityStatus>
|
||||||
|
|
||||||
Define VHOST_FQDN $vhostFQDN
|
|
||||||
<VirtualHost *:80>
|
<VirtualHost *:80>
|
||||||
<Perl>
|
<Perl>
|
||||||
$ENV{'PERL_CONF_DEBUG'} and print "------- Generation du vhosts $vhostFQDN -------\n";
|
$ENV{'PERL_CONF_DEBUG'} and print "------- Generation du vhosts $vhostFQDN -------\n";
|
||||||
|
@ -387,7 +383,7 @@ Define VHOST_FQDN $vhostFQDN
|
||||||
Use ErrorDocumentPages
|
Use ErrorDocumentPages
|
||||||
|
|
||||||
# Gestion de la page de maintenance
|
# Gestion de la page de maintenance
|
||||||
Use CheckMaintenancePage
|
Use CheckMaintenancePage $vhostFQDN
|
||||||
|
|
||||||
# Gestion mod_security et inclusion des exceptions
|
# Gestion mod_security et inclusion des exceptions
|
||||||
<IfModule mod_security2.c>
|
<IfModule mod_security2.c>
|
||||||
|
@ -408,7 +404,6 @@ Define VHOST_FQDN $vhostFQDN
|
||||||
</Perl>
|
</Perl>
|
||||||
|
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
Undefine VHOST_FQDN
|
|
||||||
</Macro>
|
</Macro>
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue