lighttpd: Add redirects for deprecated EE domains.
[matthijs/servers/drsnuggles.git] / etc / lighttpd / vhosts / evolution-events-nl
index ca5e1bf55e79175045896e6836831c6e87a96b2a..848f47564f44c46b85dbbb062e30aa284e4839a9 100644 (file)
@@ -9,7 +9,7 @@ $HTTP["host"] =~ ".evolution-events.nl$" {
        evhost.path-pattern  = var.site-dir + "/htdocs/%3/"
        accesslog.filename   = var.site-dir + "/logs/access.log"
        
-       fastcgi.server = ( 
+       fastcgi.server += ( 
                ".php" => 
                ((
                        "socket" => var.site-fcgi-dir + "/php",
@@ -19,24 +19,23 @@ $HTTP["host"] =~ ".evolution-events.nl$" {
                ((
                        "socket" => var.site-fcgi-dir + "/wipi",
                        "check-local" => "disable",
-                       "broken-scriptfilename" => "enable",
                )),
        )
-       alias.url = (
+       alias.url += (
                # Don't name this /wipistatic, since that will be caught by fastcgi above
                "/staticwipi" => var.site-dir + "/applications/wipi/static/",
        )
        
-       url.rewrite-once = (
+       url.rewrite-once += (
                "^/wipi/static/(.*)$" => "/staticwipi/$1",
-               "^(/.*)$" => "$1",
+               "^/Site(/.*|\?.*|)$" => "/wipi/Site/$1",
        )
 
        $HTTP["host"] =~ "^orga.evolution-events.nl$" {
                auth.backend                 = "plain"
                auth.backend.plain.userfile  = var.site-dir + "/conf/simple.user"
 
-               auth.require    = ( "/private" => 
+               auth.require    += ( "/private" => 
                        ( 
                                "method"  => "digest",
                                "realm"   => "Evolution Events",
@@ -45,13 +44,36 @@ $HTTP["host"] =~ ".evolution-events.nl$" {
                )
                
 
-               url.rewrite-once = (
+               url.rewrite-once += (
                        "^/forum/(.+)$" => "/forum/",
                )
        }
 
+       $HTTP["host"] =~ "^hunter-net.evolution-events.nl$" {
+               fastcgi.server  += ( 
+                       "/blaa" =>
+                       ((
+                               "socket" => var.site-fcgi-dir + "/hunternet",
+                               "check-local" => "disable",
+                       )),
+               )
+
+               alias.url += (
+                       "/media/" => "/usr/share/python-support/python-django/django/contrib/admin/media/",
+                       "/static/" => var.site-dir + "/applications/xerxes/media/",
+               )
+
+               url.rewrite-once += (
+#                      "^(/.*)$" => "/",
+                       "^(/media.*)$" => "$1",
+                       "^(/static.*)$" => "$1",
+                       "^/favicon\.ico$" => "/media/favicon.ico",
+                       "^(/.*)$" => "/blaa$1",
+               )
+       }
+
        $HTTP["host"] =~ "^xerxes.evolution-events.nl$" {
-               fastcgi.server  = ( 
+               fastcgi.server  += ( 
                        "/blaa" =>
                        ((
                                "socket" => var.site-fcgi-dir + "/xerxes",
@@ -59,16 +81,31 @@ $HTTP["host"] =~ ".evolution-events.nl$" {
                        )),
                )
 
-               alias.url = (
+               alias.url += (
                        "/media/" => "/home/matthijs/django/contrib/admin/media/",
                        "/static/" => var.site-dir + "/applications/xerxes/static/",
                )
 
-               url.rewrite-once = (
+               url.rewrite-once += (
+#                      "^(/.*)$" => "/",
                        "^(/media.*)$" => "$1",
                        "^(/static.*)$" => "$1",
                        "^/favicon\.ico$" => "/media/favicon.ico",
                        "^(/.*)$" => "/blaa$1",
                )
        }
+       
+       # Redirect some deprecated urls.
+       $HTTP["host"] =~ "^lextalionis2.evolution-events.nl$" {
+               url.redirect = ( "^(.*)$" => "http://lextalionis.evolution-events.nl$1" )
+       }
+       $HTTP["host"] =~ "^raganorck2.evolution-events.nl$" {
+               url.redirect = ( "^(.*)$" => "http://raganorck.evolution-events.nl$1" )
+       }
+       $HTTP["host"] =~ "^exodus2.evolution-events.nl$" {
+               url.redirect = ( "^(.*)$" => "http://exodus.evolution-events.nl$1" )
+       }
+       $HTTP["host"] =~ "^www2.evolution-events.nl$" {
+               url.redirect = ( "^(.*)$" => "http://www.evolution-events.nl$1" )
+       }
 }