## primitive virtual host support

$HTTP["host"] =~ "demo\.superglue\.it$" {
  server.document-root = "/www/htdocs-demo" 
  server.upload-dirs = ( "/www/tmp" )
  server.errorlog = "/www/log/demo-error.log"
  accesslog.filename = "/www/log/demo-access.log"

  $HTTP["request-method"] == "GET" {
    alias.url = (
      "/resources"  =>  "/www/lib/resources",
      ""            => "/www/lib/cgi/demo.cgi"
    )
  }

  $HTTP["request-method"] == "POST" {
    alias.url = (
      ""          =>  "/www/lib/cgi/post.cgi"
    )
    ## disable authentication
    auth.require = ""
  }
}
