Revision
656
Author
misc
Date
2011-01-05 20:09:50 +0100 (Wed, 05 Jan 2011)

Log Message

- add a module to handle various websites, mainly for storing
them.
- add the redirection of donate, asked by rda on sysadm ml

Added Paths

Added: puppet/modules/websites/manifests/init.pp
===================================================================
--- puppet/modules/websites/manifests/init.pp	                        (rev 0)
+++ puppet/modules/websites/manifests/init.pp	2011-01-05 19:09:50 UTC (rev 656)
@@ -0,0 +1,8 @@
+class websites {
+    # should expire on June 2011
+    class donate {
+        apache::vhost_other_app { "donate.$domain":
+            vhost_file => "websites/vhost_donate.conf",
+        }
+    }
+}

Added: puppet/modules/websites/templates/vhost_donate.conf
===================================================================
--- puppet/modules/websites/templates/vhost_donate.conf	                        (rev 0)
+++ puppet/modules/websites/templates/vhost_donate.conf	2011-01-05 19:09:50 UTC (rev 656)
@@ -0,0 +1,14 @@
+<VirtualHost *:80>
+    ServerName donate.<%= domain %>
+
+    RewriteEngine on
+    RewriteRule ^/(.*)$ http://www.<%= domain %>/$1/donate/ [R=permanent,L]
+    #DocumentRoot /dev/null
+    CustomLog /var/log/httpd/donate_log combined
+    ErrorLog  /var/log/httpd/error_donate_log
+ 
+    <Location />
+       Allow from all
+    </Location>
+
+</VirtualHost>