fix error on dynmic web domain vhosts

This commit is contained in:
Peter Hormanns 2013-05-09 16:51:34 +02:00
parent 855ab2551a
commit d63deeceae
2 changed files with 7 additions and 6 deletions

View File

@ -271,6 +271,7 @@ public class DomainProcessorFactory implements EntityProcessorFactory {
private Processor createApacheVHostSetupProcessor(EntityManager em, Domain dom) throws ProcessorException { private Processor createApacheVHostSetupProcessor(EntityManager em, Domain dom) throws ProcessorException {
Map<String, Object> templateVars = new HashMap<String, Object>(); Map<String, Object> templateVars = new HashMap<String, Object>();
templateVars.put("dom", dom);
String domName = dom.getName(); String domName = dom.getName();
int level = domName.split("\\.").length; int level = domName.split("\\.").length;
String linkPrefix = Integer.toString(100 - level); String linkPrefix = Integer.toString(100 - level);

View File

@ -13,7 +13,7 @@
DocumentRoot /home/doms/${dom.name}/htdocs DocumentRoot /home/doms/${dom.name}/htdocs
#if( ${dom.isDynamic} ) #if( ${dom.dynamic} )
Alias /cgi-bin/ /home/doms/${dom.name}/cgi/ Alias /cgi-bin/ /home/doms/${dom.name}/cgi/
Alias /fastcgi-bin/ /home/doms/${dom.name}/fastcgi/ Alias /fastcgi-bin/ /home/doms/${dom.name}/fastcgi/
#end #end
@ -26,7 +26,7 @@
AllowOverride AuthConfig FileInfo Indexes Limit AllowOverride AuthConfig FileInfo Indexes Limit
</Directory> </Directory>
#if( ${dom.isDynamic} ) #if( ${dom.dynamic} )
<Location /cgi-bin/> <Location /cgi-bin/>
SetHandler cgi-script SetHandler cgi-script
Options +ExecCGI ${includes} -Indexes -MultiViews +SymLinksIfOwnerMatch Options +ExecCGI ${includes} -Indexes -MultiViews +SymLinksIfOwnerMatch
@ -63,7 +63,7 @@
RewriteRule ^(.*) - [redirect=404,last] RewriteRule ^(.*) - [redirect=404,last]
#end #end
#if( ${dom.isDynamic} ) #if( ${dom.dynamic} )
AddType application/x-httpd-php .php .php5 .php4 .php3 AddType application/x-httpd-php .php .php5 .php4 .php3
Action application/x-httpd-php /fastcgi-bin/phpstub Action application/x-httpd-php /fastcgi-bin/phpstub
#end #end
@ -86,7 +86,7 @@
DocumentRoot /home/doms/${dom.name}/htdocs-ssl DocumentRoot /home/doms/${dom.name}/htdocs-ssl
#if( ${pac.dynamicWeb} || ${dom.pacDomain} ) #if( ${dom.dynamic} )
Alias /cgi-bin/ /home/doms/${dom.name}/cgi-ssl/ Alias /cgi-bin/ /home/doms/${dom.name}/cgi-ssl/
Alias /fastcgi-bin/ /home/doms/${dom.name}/fastcgi-ssl/ Alias /fastcgi-bin/ /home/doms/${dom.name}/fastcgi-ssl/
#end #end
@ -100,7 +100,7 @@
AllowOverride AuthConfig FileInfo Indexes Limit AllowOverride AuthConfig FileInfo Indexes Limit
</Directory> </Directory>
#if( ${pac.dynamicWeb} || ${dom.pacDomain} ) #if( ${dom.dynamic} )
<Location /cgi-bin/> <Location /cgi-bin/>
SetHandler cgi-script SetHandler cgi-script
Options +ExecCGI ${includes} -Indexes -MultiViews +SymLinksIfOwnerMatch Options +ExecCGI ${includes} -Indexes -MultiViews +SymLinksIfOwnerMatch
@ -137,7 +137,7 @@
RewriteRule ^(.*) - [redirect=404,last] RewriteRule ^(.*) - [redirect=404,last]
#end #end
#if( ${pac.dynamicWeb} || ${dom.pacDomain} ) #if( ${dom.dynamic} )
AddType application/x-httpd-php .php .php5 .php4 .php3 AddType application/x-httpd-php .php .php5 .php4 .php3
Action application/x-httpd-php /fastcgi-bin/phpstub Action application/x-httpd-php /fastcgi-bin/phpstub
#end #end