Accès Rapide :
Navigation Sécurisée | M'identifier | M'inscrire | Rechercher |
Imprimer |
Webmail
Apache2 en Virtual DocumentRoot avec php4 et php5
vi /etc/apache2/apache2.conf
001 // php4 mod - php5 cgi && mod suExec
002 AddHandler php5-script .php5
003 Action php5-script /cgi/php5-cgi
004 #SuexecUserGroup apache4 apache40
005
006 //...
007 NameVirtualHost *
008
009 <VirtualHost *>
010 ServerAdmin %72%6f%6f%74%40%6c%61%62%33%77%2e%63%6f%6d
011 DirectoryIndex index.html index.htm index.shtml index.php index.php4 index.php5 index.cgi index.pl index.gz user.php
012
013 LogFormat "%V %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i \" \"%{forensic-id}n\" %v" combinedvhost
014 CustomLog "/var/log/apache2/access.log" combined
015 CustomLog "| /usr/sbin/split-logfile" combinedvhost
016
017 UseCanonicalName Off
018 VirtualDocumentRoot /home/prod/vhosts/%0
019 # VirtualScriptAlias /home/prod/vhosts/%0/cgi
020
021 <Directory />
022 Order Deny,Allow
023 Allow from all
024 Options FollowSymLinks -Indexes +ExecCGI
025 AllowOverride All AuthConfig
026 </Directory>
027
028 <Directory /home/prod/vhosts/*/pub/>
029 Order Allow,Deny
030 Allow from all
031 Options FollowSymLinks +Indexes
032 AllowOverride All AuthConfig
033 </Directory>
034
035 <Directory /home/prod/vhosts/*/cgi/>
036 Order Allow,Deny
037 Allow from all
038 Options FollowSymLinks -Indexes +ExecCGI
039 SetHandler cgi-script
040 AllowOverride None
041 </Directory>
042
043 <IfModule mod_throttle.c>
044 ThrottlePolicy none
045 <Location /throttle-status>
046 SetHandler throttle-status
047 </Location>
048 </IfModule>
049
050 <IfModule rewrite_module>
051 RewriteEngine On
052
053 RewriteCond %{HTTP_HOST} ^patie\.web\.lab3w\.com.* [NC]
054 RewriteRule ^(.*) https://patie.web.lab3w.com:444$1 [L,R]
055
056 RewriteCond %{HTTP_HOST} ^w3a\.lab3w\.com.* [NC]
057 RewriteCond %{REQUEST_URI} ^/gestion.* [NC]
058 RewriteRule ^(.*) https://w3a.lab3w.com:444$1 [L,R]
059
060 RewriteCond %{HTTP_HOST} ^phpmyadmin\.wwweball\.com.* [NC]
061 RewriteRule ^(.*) https://phpmyadmin.wwweball.com$1 [L,R]
062
063 RewriteCond %{HTTP_HOST} ^wifi\.wwweball\.com.* [OR]
064 RewriteCond %{HTTP_HOST} ^wireless\.wwweball\.com.* [OR]
065 RewriteCond %{HTTP_HOST} ^olsr\.wwweball\.com.* [NC]
066 RewriteRule ^(.*) http://www2.wwweball.com/wireless$1 [L,R]
067
068 RewriteCond %{HTTP_HOST} ^www\.openworldzone\.com.* [OR]
069 RewriteCond %{HTTP_HOST} ^openworldzone\.net.* [OR]
070 RewriteCond %{HTTP_HOST} ^openworldzone\.com.* [NC]
071 RewriteRule ^(.*) http://www.openworldzone.net$1 [L,R]
072
073 RewriteCond %{HTTP_HOST} ^v2\.wwweball\.com.* [NC]
074 RewriteRule ^(.*) http://www2.wwweball.com$1 [L,R]
075
076 RewriteCond %{HTTP_HOST} ^wiki\.wwweball\.com.* [NC]
077 RewriteRule ^(.*) http://www2.wwweball.com/wiki$1 [L,R]
078
079 RewriteCond %{HTTP_HOST} ^wifi\.lab3w\.com.* [NC]
080 RewriteRule ^(.*) http://www2.wwweball.com/wireless/France/92/Montrouge$1 [L,R]
081 </IfModule>
082
083 </VirtualHost>
084
085 <VirtualHost 192.168.92.2:443>
086 SSLEngine on
087 SSLCertificateFile LAB3W-RootSecureCerticateSigning-wWwEBALL.com.crt
088 SSLCertificateKeyFile LAB3W-RootSecureCerticateSigning-wWwEBALL.com.key
089
090 ServerAdmin %72%6f%6f%74%40%6c%61%62%33%77%2e%63%6f%6d
091 DirectoryIndex index.html index.htm index.shtml index.php index.php4 index.php5 index.cgi index.pl index.gz user.php
092
093 LogFormat "%V %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i \" \"%{forensic-id}n\" %v" combinedvhost
094 CustomLog "/var/log/apache2/access.log" combined
095 CustomLog "| /usr/sbin/split-logfile" combinedvhost
096
097 UseCanonicalName Off
098 VirtualDocumentRoot /home/prod/vhosts/%0
099
100 <Directory />
101 Order Deny,Allow
102 Allow from all
103 Options FollowSymLinks -Indexes
104 AllowOverride All AuthConfig
105 </Directory>
106
107 <Directory /home/prod/vhosts/*/pub/>
108 Order Allow,Deny
109 Allow from all
110 Options FollowSymLinks +Indexes
111 AllowOverride All AuthConfig
112 </Directory>
113
114 <IfModule rewrite_module>
115 RewriteEngine On
116
117 RewriteCond %{SERVER_PORT} ^443$ [NC]
118 RewriteCond %{HTTP_HOST} ^w3a\.lab3w\.com.* [NC]
119 RewriteRule ^(.*) https://w3a.lab3w.com:444$1 [L,R]
120
121 RewriteCond %{SERVER_PORT} ^443$ [NC]
122 RewriteCond %{HTTP_HOST} ^patie\.web\.lab3w\.com.* [NC]
123 RewriteRule ^(.*) https://patie.web.lab3w.com:444$1 [L,R]
124 </IfModule>
125
126 </VirtualHost>
127
128 <VirtualHost 192.168.92.2:444>
129 SSLEngine on
130 SSLCertificateFile LAB3W-RootSecureCerticateSigning-Lab3w.com.crt
131 SSLCertificateKeyFile LAB3W-RootSecureCerticateSigning-Lab3w.com.key
132
133 # ServerAdmin root(at)lab3w(dot)com
134 ServerAdmin %72%6f%6f%74%40%6c%61%62%33%77%2e%63%6f%6d
135 DirectoryIndex index.html index.htm index.shtml index.php index.php4 index.php5 index.cgi index.pl index.gz user.php
136
137 UseCanonicalName Off
138 VirtualDocumentRoot /home/prod/vhosts/%0
139
140 <Directory />
141 Order Deny,Allow
142 Allow from all
143 Options FollowSymLinks -Indexes +ExecCGI
144 AllowOverride All AuthConfig
145 </Directory>
146
147 </VirtualHost>
Toutes les contributions à wiki.wwweball.com sont considérées comme publiées sous les termes de la GNU Free Documentation Licence, une licence de documentation libre.
Si vous ne désirez pas que vos écrits soient édités et distribués à volonté, ne les envoyez pas.
De même, merci de ne contribuer qu'en apportant vos propres écrits ou des écrits issus d'une source libre de droits.
N'UTILISEZ PAS DE TRAVAUX SOUS COPYRIGHT SANS AUTORISATION EXPRESSE !