85 lines
2.6 KiB
Plaintext
85 lines
2.6 KiB
Plaintext
<!-- BEGIN: main --><VirtualHost {DOM_IPNUMBER}:80 {DOM_IPNUMBEREX}:80>
|
|
|
|
ServerName {DOM_HOSTNAME}
|
|
ServerAlias *.{DOM_HOSTNAME}
|
|
ServerAdmin {DOM_USERNAME}@{HIVE}.hostsharing.net
|
|
|
|
SuexecUserGroup {DOM_USERNAME} {PAC}
|
|
|
|
DocumentRoot /home/doms/{DOM_HOSTNAME}/htdocs
|
|
|
|
<Directory />
|
|
Options -ExecCGI +IncludesNOEXEC +Indexes +MultiViews +SymLinksIfOwnerMatch
|
|
</Directory>
|
|
|
|
<Directory /home/doms/{DOM_HOSTNAME}/>
|
|
AllowOverride AuthConfig FileInfo Indexes Limit
|
|
</Directory>
|
|
|
|
<Location /cgi-bin/>
|
|
Redirect 501 /
|
|
</Location>
|
|
|
|
<Location /fastcgi-bin/>
|
|
Redirect 501 /
|
|
</Location>
|
|
|
|
RewriteEngine On
|
|
RewriteOptions Inherit
|
|
|
|
RewriteCond %{HTTP_HOST} ^(.+)\.{DOM_HOSTNAME}\.?(:80)?$ [novary]
|
|
RewriteCond /home/doms/{DOM_HOSTNAME}/subs/${tolower:%1} -d
|
|
RewriteRule ^(.*) /home/doms/{DOM_HOSTNAME}/subs/${tolower:%1}$1 [last]
|
|
|
|
<!-- BEGIN: iterate --> RewriteCond %{HTTP_HOST} ^(.+)\.{DOM_HOSTNAME}\.?(:80)?$ [novary]
|
|
RewriteCond /home/doms/{DOM_HOSTNAME}/subs/${tolower:%1} !-d
|
|
RewriteRule ^(.*) - [redirect=404,last]
|
|
<!-- END: iterate -->
|
|
</VirtualHost>
|
|
|
|
<VirtualHost {DOM_IPNUMBER}:443 {DOM_IPNUMBEREX}:443>
|
|
|
|
ServerName {DOM_HOSTNAME}
|
|
ServerAlias *.{DOM_HOSTNAME}
|
|
ServerAdmin {DOM_USERNAME}@{HIVE}.hostsharing.net
|
|
|
|
SuexecUserGroup {DOM_USERNAME} {PAC}
|
|
|
|
SSLEngine On
|
|
SSLCertificateFile /etc/apache2/pems/default.pem
|
|
SSLCertificateChainFile /etc/apache2/pems/default.chain.pem
|
|
SSLCertificateFile /etc/apache2/pems/{PAC}.pem
|
|
SSLCertificateChainFile /etc/apache2/pems/{PAC}.chain.pem
|
|
|
|
DocumentRoot /home/doms/{DOM_HOSTNAME}/htdocs-ssl
|
|
|
|
<Directory />
|
|
SSLRequireSSL On
|
|
Options -ExecCGI +IncludesNOEXEC +Indexes +MultiViews +SymLinksIfOwnerMatch
|
|
</Directory>
|
|
|
|
<Directory /home/doms/{DOM_HOSTNAME}/>
|
|
AllowOverride AuthConfig FileInfo Indexes Limit
|
|
</Directory>
|
|
|
|
<Location /cgi-bin/>
|
|
Redirect 501 /
|
|
</Location>
|
|
|
|
<Location /fastcgi-bin/>
|
|
Redirect 501 /
|
|
</Location>
|
|
|
|
RewriteEngine On
|
|
RewriteOptions Inherit
|
|
|
|
RewriteCond %{HTTP_HOST} ^(.+)\.{DOM_HOSTNAME}\.?(:443)?$ [novary]
|
|
RewriteCond /home/doms/{DOM_HOSTNAME}/subs-ssl/${tolower:%1} -d
|
|
RewriteRule ^(.*) /home/doms/{DOM_HOSTNAME}/subs-ssl/${tolower:%1}$1 [last]
|
|
|
|
<!-- BEGIN: nosubdomainfallbackforhttps --> RewriteCond %{HTTP_HOST} ^(.+)\.{DOM_HOSTNAME}\.?(:443)?$ [novary]
|
|
RewriteCond /home/doms/{DOM_HOSTNAME}/subs-ssl/${tolower:%1} !-d
|
|
RewriteRule ^(.*) - [redirect=404,last]
|
|
|
|
<!-- END: nosubdomainfallbackforhttps --></VirtualHost>
|
|
<!-- END: main --> |