commit | author | age
|
c09e9b
|
1 |
# |
6208e0
|
2 |
# This file is managed by HSAdmin. |
PH |
3 |
# Do not edit manually. Changes will be overwritten. |
|
4 |
# |
|
5 |
|
09e7b1
|
6 |
<VirtualHost ${pac.curINetAddr.inet4Addr}:80 ${pac.oldINetAddr.inet4Addr}:80> |
6208e0
|
7 |
ServerName ${dom.name} |
bf2b35
|
8 |
ServerAlias ${dom.serveraliases} |
6208e0
|
9 |
ServerAdmin webmaster@${dom.name} |
PH |
10 |
|
|
11 |
SuexecUserGroup ${dom.user.name} ${pac.name} |
|
12 |
|
bf2b35
|
13 |
PassengerEnabled Off |
ee5e33
|
14 |
PassengerUser ${dom.user.name} |
MH |
15 |
PassengerGroup ${pac.name} |
|
16 |
PassengerAppRoot /home/doms/${dom.name}/app/ |
|
17 |
|
6208e0
|
18 |
DocumentRoot /home/doms/${dom.name}/htdocs |
PH |
19 |
|
|
20 |
Alias /cgi-bin/ /home/doms/${dom.name}/cgi/ |
|
21 |
Alias /fastcgi-bin/ /home/doms/${dom.name}/fastcgi/ |
bf2b35
|
22 |
#if( ${letsencrypt} ) |
4ec40e
|
23 |
Alias /.well-known/acme-challenge/ /var/lib/hostsharing/acmebot/webroot/${dom.name}/ |
bf2b35
|
24 |
#end |
6208e0
|
25 |
|
PH |
26 |
<Directory /> |
46a14f
|
27 |
PassengerEnabled Off |
6208e0
|
28 |
Options -ExecCGI ${includes} ${indexes} ${multiviews} +SymLinksIfOwnerMatch |
PH |
29 |
</Directory> |
|
30 |
|
|
31 |
<Directory /home/doms/${dom.name}/> |
46a14f
|
32 |
PassengerEnabled On |
f423b9
|
33 |
AllowOverride AuthConfig FileInfo Indexes Limit Options=ExecCGI,IncludesNoExec,Indexes,MultiViews,SymLinksIfOwnerMatch,PassengerNodejs,PassengerPython,PassengerRuby,PassengerAppEnv |
6208e0
|
34 |
</Directory> |
PH |
35 |
|
|
36 |
<Location /cgi-bin/> |
46a14f
|
37 |
PassengerEnabled Off |
6208e0
|
38 |
SetHandler cgi-script |
340686
|
39 |
Options +ExecCGI +IncludesNoExec -Indexes -MultiViews +SymLinksIfOwnerMatch |
6208e0
|
40 |
</Location> |
PH |
41 |
|
|
42 |
<Location /fastcgi-bin/> |
46a14f
|
43 |
PassengerEnabled Off |
6208e0
|
44 |
SetHandler fcgid-script |
340686
|
45 |
Options +ExecCGI +IncludesNoExec -Indexes -MultiViews +SymLinksIfOwnerMatch |
6208e0
|
46 |
</Location> |
PH |
47 |
|
cee6cc
|
48 |
#if( ${phplatest} ) |
PH |
49 |
FcgidInitialEnv HTTP_PHP_BIN /usr/lib/cgi-bin/php7.3 |
b28d34
|
50 |
|
605701
|
51 |
#end |
6208e0
|
52 |
RewriteEngine On |
PH |
53 |
RewriteOptions Inherit |
|
54 |
|
|
55 |
RewriteCond %{REQUEST_URI} !^/cgi-bin/ |
bf2b35
|
56 |
RewriteCond %{REQUEST_URI} !^/fastcgi-bin/ |
PH |
57 |
#if( ${letsencrypt} ) |
|
58 |
RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/ |
|
59 |
#end |
2e99a9
|
60 |
RewriteCond %{HTTP_HOST} ^(.+)\.${dom.name}\.?(:[0-9]+)?$ [novary] |
747bf3
|
61 |
RewriteCond /home/doms/${dom.name}/subs/#[[${tolower:%1} ]]# -d |
c09e9b
|
62 |
RewriteRule ^(.*) /home/doms/${dom.name}/subs/#[[${tolower:%1}$1 ]]# [last] |
MH |
63 |
|
6208e0
|
64 |
#if( !${htdocsfallback} ) |
PH |
65 |
RewriteCond %{REQUEST_URI} !^/cgi-bin/ |
7a0aad
|
66 |
RewriteCond %{REQUEST_URI} !^/fastcgi-bin/ |
bf2b35
|
67 |
#if( ${letsencrypt} ) |
PH |
68 |
RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/ |
|
69 |
#end |
89b2b3
|
70 |
RewriteCond %{HTTP_HOST} ^(.+)\.${dom.name}\.?(:80)?$ [novary] |
747bf3
|
71 |
RewriteCond /home/doms/${dom.name}/subs/#[[${tolower:%1} ]]# !-d |
6208e0
|
72 |
RewriteRule ^(.*) - [redirect=404,last] |
c09e9b
|
73 |
|
6365b4
|
74 |
#end |
6208e0
|
75 |
AddType application/x-httpd-php .php .php5 .php4 .php3 |
PH |
76 |
Action application/x-httpd-php /fastcgi-bin/phpstub |
|
77 |
</VirtualHost> |
|
78 |
|
09e7b1
|
79 |
<VirtualHost ${pac.curINetAddr.inet4Addr}:443 ${pac.oldINetAddr.inet4Addr}:443> |
6208e0
|
80 |
ServerName ${dom.name} |
bf2b35
|
81 |
ServerAlias ${dom.serveraliases} |
a62974
|
82 |
ServerAdmin webmaster@${dom.name} |
6208e0
|
83 |
|
PH |
84 |
SuexecUserGroup ${dom.user.name} ${pac.name} |
c09e9b
|
85 |
|
bf2b35
|
86 |
PassengerEnabled Off |
ee5e33
|
87 |
PassengerUser ${dom.user.name} |
MH |
88 |
PassengerGroup ${pac.name} |
|
89 |
PassengerAppRoot /home/doms/${dom.name}/app-ssl/ |
6208e0
|
90 |
|
PH |
91 |
SSLEngine On |
2c91cd
|
92 |
SSLCertificateFile /etc/apache2/pems-enabled/${dom.name}.crt |
PH |
93 |
SSLCertificateKeyFile /etc/apache2/pems-enabled/${dom.name}.key |
|
94 |
SSLCertificateChainFile /etc/apache2/pems-enabled/${dom.name}.chain |
c09e9b
|
95 |
|
6208e0
|
96 |
DocumentRoot /home/doms/${dom.name}/htdocs-ssl |
PH |
97 |
|
|
98 |
Alias /cgi-bin/ /home/doms/${dom.name}/cgi-ssl/ |
|
99 |
Alias /fastcgi-bin/ /home/doms/${dom.name}/fastcgi-ssl/ |
bf2b35
|
100 |
#if( ${letsencrypt} ) |
4ec40e
|
101 |
Alias /.well-known/acme-challenge/ /var/lib/hostsharing/acmebot/webroot/${dom.name}/ |
bf2b35
|
102 |
#end |
6208e0
|
103 |
|
PH |
104 |
<Directory /> |
66113d
|
105 |
SSLRequireSSL On |
46a14f
|
106 |
PassengerEnabled Off |
6208e0
|
107 |
Options -ExecCGI ${includes} ${indexes} ${multiviews} +SymLinksIfOwnerMatch |
PH |
108 |
</Directory> |
|
109 |
|
|
110 |
<Directory /home/doms/${dom.name}/> |
10baac
|
111 |
PassengerEnabled On |
f423b9
|
112 |
AllowOverride AuthConfig FileInfo Indexes Limit Options=ExecCGI,IncludesNoExec,Indexes,MultiViews,SymLinksIfOwnerMatch,PassengerNodejs,PassengerPython,PassengerRuby,PassengerAppEnv |
6208e0
|
113 |
</Directory> |
PH |
114 |
|
|
115 |
<Location /cgi-bin/> |
10baac
|
116 |
PassengerEnabled Off |
6208e0
|
117 |
SetHandler cgi-script |
340686
|
118 |
Options +ExecCGI +IncludesNoExec -Indexes -MultiViews +SymLinksIfOwnerMatch |
6208e0
|
119 |
</Location> |
PH |
120 |
|
|
121 |
<Location /fastcgi-bin/> |
a62974
|
122 |
PassengerEnabled Off |
6208e0
|
123 |
SetHandler fcgid-script |
340686
|
124 |
Options +ExecCGI +IncludesNoExec -Indexes -MultiViews +SymLinksIfOwnerMatch |
6208e0
|
125 |
</Location> |
c09e9b
|
126 |
|
MH |
127 |
#if( ${phplatest} ) |
|
128 |
FcgidInitialEnv HTTP_PHP_BIN /usr/lib/cgi-bin/php7.3 |
|
129 |
|
|
130 |
#end |
6208e0
|
131 |
RewriteEngine On |
PH |
132 |
RewriteOptions Inherit |
c09e9b
|
133 |
|
6208e0
|
134 |
RewriteCond %{REQUEST_URI} !^/cgi-bin/ |
c09e9b
|
135 |
RewriteCond %{REQUEST_URI} !^/fastcgi-bin/ |
bf2b35
|
136 |
#if( ${letsencrypt} ) |
PH |
137 |
RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/ |
|
138 |
#end |
747bf3
|
139 |
RewriteCond %{HTTP_HOST} ^(.+)\.${dom.name}\.?(:[0-9]+)?$ [novary] |
PH |
140 |
RewriteCond /home/doms/${dom.name}/subs-ssl/#[[${tolower:%1} ]]# -d |
c09e9b
|
141 |
RewriteRule ^(.*) /home/doms/${dom.name}/subs-ssl/#[[${tolower:%1}$1 ]]# [last] |
MH |
142 |
|
6208e0
|
143 |
#if( !${htdocsfallback} ) |
PH |
144 |
RewriteCond %{REQUEST_URI} !^/cgi-bin/ |
7a0aad
|
145 |
RewriteCond %{REQUEST_URI} !^/fastcgi-bin/ |
bf2b35
|
146 |
#if( ${letsencrypt} ) |
PH |
147 |
RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/ |
|
148 |
#end |
747bf3
|
149 |
RewriteCond %{HTTP_HOST} ^(.+)\.${dom.name}\.?(:443)?$ [novary] |
PH |
150 |
RewriteCond /home/doms/${dom.name}/subs-ssl/#[[${tolower:%1} ]]# !-d |
6208e0
|
151 |
RewriteRule ^(.*) - [redirect=404,last] |
c09e9b
|
152 |
|
6208e0
|
153 |
#end |
PH |
154 |
AddType application/x-httpd-php .php .php5 .php4 .php3 |
|
155 |
Action application/x-httpd-php /fastcgi-bin/phpstub |
d24c19
|
156 |
|
6208e0
|
157 |
</VirtualHost> |