# Basic setup
server.port = 8080
server.tag = "lighttpd"
server.use-ipv6 = "enable"
server.document-root = var.CWD + "/"
server.modules += ("mod_fastcgi")

# For performance tweaking see:
# http://www.debianhelp.co.uk/performancelighttpd.htm
#server.max-fds = 2048
#server.max-keep-alive-requests = 4
#server.max-keep-alive-idle = 4

# Server status
#server.modules += ("mod_status")
#status.status-url = "/server-status"
#status.statistics-url = "/server-stats"
#status.config-url = "/server-config"
#status.enable-sort = "enable"

# Documentation access
#server.modules += ("mod_alias")
#index-file.names = ("index.html")
#alias.url = ( "/docs/" => var.CWD + "/doc/api/" )

# Debug lighttpd
#server.max-keep-alive-requests = 0
#debug.log-request-header = "enable" # log all request headers.
#debug.log-file-not-found = "enable" # log if a file wasn't found.
#debug.log-condition-handling = "enable" # log conditionals handling for debugging.
#debug.log-request-header-on-error = "enable" # log request header, but only when there is an error.
#debug.log-request-handling = "enable" # log request handling inside lighttpd.
#debug.log-state-handling = "enable" # log state handling inside lighttpd.
#debug.log-response-header = "enable" # log the header we send out to the client.
#debug.dump-unknown-headers = "enable" # log listing of internally unhandled HTTP-headers. 

# Some MIME-types
mimetype.assign = (  
  ".css"    => "text/css",
  ".gif"    => "image/gif",
  ".htm"    => "text/html",
  ".html"   => "text/html",
  ".jpeg"   => "image/jpeg",
  ".jpg"    => "image/jpeg",
  ".js"     => "text/javascript",
  ".png"    => "image/png",
  ".swf"    => "application/x-shockwave-flash",
  ".txt"    => "text/plain",
  ".tar.gz" => "application/x-tgz",
  ".gz"     => "application/x-gzip"
)
