diff --git a/hsarback/src/de/hsadmin/mods/pac/PacProcessorFactory.java b/hsarback/src/de/hsadmin/mods/pac/PacProcessorFactory.java
index 6709fe1..8625e1f 100644
--- a/hsarback/src/de/hsadmin/mods/pac/PacProcessorFactory.java
+++ b/hsarback/src/de/hsadmin/mods/pac/PacProcessorFactory.java
@@ -90,22 +90,10 @@ public class PacProcessorFactory implements EntityProcessorFactory {
private Processor createHttpdVirtualProc(Hive hive) throws ProcessorException {
Processor domSetupProcessor = new CompoundProcessor(
new CreateFileProcessor("/de/hsadmin/mods/pac/httpd-virtual.vm", hive,
- "/etc/apache2/virtual.conf.tmp", "root", "root", "644", true),
- new ShellProcessor("for PEM in $( cat /etc/apache2/virtual.conf.tmp | grep SSLCertificateFile | cut -c24- ); do " +
- "ls $PEM >/dev/null 2>&1 || ( " +
- " sed -i \"/SSLCertificateFile.*${PEM:18}/c \\\n" +
- "\\ \\ \\ \\ SSLCertificateFile \\/etc\\/apache2\\/pems\\/default.pem\" /etc/apache2/virtual.conf.tmp && " +
- " sed -i \"/SSLCertificateChainFile.*${PEM:18:5}.chain.pem/c \\\n" +
- "\\ \\ \\ \\ SSLCertificateChainFile \\/etc\\/apache2\\/pems\\/default.chain.pem\" /etc/apache2/virtual.conf.tmp " +
- "); " +
- "done"),
- new ShellProcessor("for PEM in $( cat /etc/apache2/virtual.conf.tmp | grep SSLCertificateChainFile | cut -c29- ); do " +
- "ls $PEM >/dev/null 2>&1 || " +
- " sed -i \"/SSLCertificateChainFile.*${PEM:18:5}.chain.pem/d \" /etc/apache2/virtual.conf.tmp ; " +
- "done"),
- new ShellProcessor("(diff -q /etc/apache2/virtual.conf.tmp /etc/apache2/virtual.conf"
- + " && rm /etc/apache2/virtual.conf.tmp )"
- + " || ( mv /etc/apache2/virtual.conf.tmp /etc/apache2/virtual.conf "
+ "/etc/apache2/conf.d/virtual.conf.tmp", "root", "root", "644", true),
+ new ShellProcessor("(diff -q /etc/apache2/conf.d/virtual.conf.tmp /etc/apache2/conf.d/virtual.conf"
+ + " && rm /etc/apache2/conf.d/virtual.conf.tmp )"
+ + " || ( mv /etc/apache2/conf.d/virtual.conf.tmp /etc/apache2/conf.d/virtual.conf "
+ " && invoke-rc.d apache2 reload >/dev/null 2>&1 ) "));
return domSetupProcessor;
}
diff --git a/hsarback/src/de/hsadmin/mods/pac/httpd-virtual.vm b/hsarback/src/de/hsadmin/mods/pac/httpd-virtual.vm
index c59691d..49a8d3d 100644
--- a/hsarback/src/de/hsadmin/mods/pac/httpd-virtual.vm
+++ b/hsarback/src/de/hsadmin/mods/pac/httpd-virtual.vm
@@ -4,8 +4,29 @@
#
#foreach( $pac in ${hive.pacs} )
+
+ ServerName _
+ ServerAdmin webmaster@${pac.getName}
-# ${pac.name}
-NameVirtualHost ${pac.curINetAddr.inetAddr}:80
-NameVirtualHost ${pac.curINetAddr.inetAddr}:443
-#end
+
+ Redirect 404 /
+
+
+
+
+
+ ServerName _
+ ServerAdmin webmaster@${pac.getName}
+
+ SSLEngine On
+ SSLCertificateFile /etc/apache2/pems/default.pem
+ SSLCertificateChainFile /etc/apache2/pems/default.chain.pem
+
+
+ SSLRequireSSL On
+ Redirect 404 /
+
+
+
+
+#end
\ No newline at end of file