Apache VHost
Zur Navigation springen
Zur Suche springen
Apache VHost
Der Standard-VHost hat bei Hostsharing die folgende Konfiguration:
Die ServerAlias-Einträge sind durch das Feld "validsubdomains" in der KOnfiguration der Domain in HSADmin definiert.
Der VHost für HTTPS enthält zusätzlich die Einträge für TLS-Zertifikate.
Die Pfade Location /autodiscover/autodiscover.xml und /.well-known/autoconfig/mail/config-v1.1.xml dienen für die Autokonfiguration von E-Mail-Clients.
<VirtualHost 83.223.x.x:80 [2a01:37:1000:0:0:53df:xxxx:0]:80> ServerName hs-example.de ServerAlias www.hs-example.de ServerAdmin webmaster@hs-example.de SuexecUserGroup xyz00-domadmin xyz00 PassengerEnabled Off PassengerUser xyz00-domadmin PassengerGroup xyz00 PassengerAppRoot /home/doms/hs-example.de/app/ DocumentRoot /home/doms/hs-example.de/htdocs Alias /cgi-bin/ /home/doms/hs-example.de/cgi/ Alias /fastcgi-bin/ /home/doms/hs-example.de/fastcgi/ <Directory /> PassengerEnabled Off Options -ExecCGI +IncludesNoExec +Indexes +MultiViews +SymLinksIfOwnerMatch </Directory> <Directory /home/doms/hs-example.de/> PassengerEnabled On AllowOverride AuthConfig FileInfo Indexes Limit Options=ExecCGI,IncludesNoExec,Indexes,MultiViews,SymLinksIfOwnerMatch,PassengerNodejs,PassengerPython,PassengerRuby,PassengerAppEnv </Directory> <Location /cgi-bin/> PassengerEnabled Off SetHandler cgi-script Options +ExecCGI +IncludesNoExec -Indexes -MultiViews +SymLinksIfOwnerMatch </Location> <Location /fastcgi-bin/> PassengerEnabled Off SetHandler fcgid-script Options +ExecCGI +IncludesNoExec -Indexes -MultiViews +SymLinksIfOwnerMatch </Location> <Location /autodiscover/autodiscover.xml> ProxyPreserveHost Off ProxyPass http://127.0.0.1:8082/ </Location> <Location /.well-known/autoconfig/mail/config-v1.1.xml> ProxyPreserveHost Off ProxyPass http://127.0.0.1:8081/ </Location> RewriteEngine On RewriteOptions Inherit RewriteCond %{REQUEST_URI} !^/cgi-bin/ RewriteCond %{REQUEST_URI} !^/fastcgi-bin/ RewriteCond %{HTTP_HOST} ^(.+)\.hs-example.de\.?(:[0-9]+)?$ [novary] RewriteCond /home/doms/hs-example.de/subs/${tolower:%1} -d RewriteRule ^(.*) /home/doms/hs-example.de/subs/${tolower:%1}$1 [last] AddType application/x-httpd-php .php .php5 .php4 .php3 Action application/x-httpd-php /fastcgi-bin/phpstub </VirtualHost>